lib/mixlib/versioning/format/opscode_semver.rb in mixlib-versioning-1.1.0 vs lib/mixlib/versioning/format/opscode_semver.rb in mixlib-versioning-1.2.1
- old
+ new
@@ -15,11 +15,11 @@
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#
-require 'mixlib/versioning/format/semver'
+require "mixlib/versioning/format/semver"
module Mixlib
class Versioning
class Format
# Defines the format of the semantic version scheme used for Opscode
@@ -69,11 +69,11 @@
# @see SemVer#parse
def parse(version_string)
super(version_string)
- fail Mixlib::Versioning::ParseError, "'#{@prerelease}' is not a valid Opscode pre-release signifier!" unless @prerelease.nil? || @prerelease.match(OPSCODE_PRERELEASE_REGEX)
- fail Mixlib::Versioning::ParseError, "'#{@build}' is not a valid Opscode build signifier!" unless @build.nil? || @build.match(OPSCODE_BUILD_REGEX)
+ raise Mixlib::Versioning::ParseError, "'#{@prerelease}' is not a valid Opscode pre-release signifier!" unless @prerelease.nil? || @prerelease.match(OPSCODE_PRERELEASE_REGEX)
+ raise Mixlib::Versioning::ParseError, "'#{@build}' is not a valid Opscode build signifier!" unless @build.nil? || @build.match(OPSCODE_BUILD_REGEX)
end
end # class OpscodeSemVer
end # class Format
end # module Versioning
end # module Mixlib