From 7e17568ada15d790f50e89b073b51b09d368faca Mon Sep 17 00:00:00 2001 From: Matt Farina Date: Fri, 13 Sep 2019 10:53:34 -0400 Subject: [PATCH] Fixes issue with module path for v3 Fixes #125 --- CHANGELOG.md | 6 ++++++ benchmark_test.go | 18 ++++++++---------- go.mod | 2 +- 3 files changed, 15 insertions(+), 11 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 6e02b86..6b1788d 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,11 @@ # Changelog +## 3.0.1 (2019-09-13) + +### Fixed + +- #125: Fixes issue with module path for v3 + ## 3.0.0 (2019-09-12) This is a major release of the semver package which includes API changes. The Go diff --git a/benchmark_test.go b/benchmark_test.go index c15d095..2804563 100644 --- a/benchmark_test.go +++ b/benchmark_test.go @@ -1,9 +1,7 @@ -package semver_test +package semver import ( "testing" - - "github.com/Masterminds/semver" ) /* Constraint creation benchmarks */ @@ -12,7 +10,7 @@ func benchNewConstraint(c string, b *testing.B) { b.ReportAllocs() b.ResetTimer() for i := 0; i < b.N; i++ { - _, _ = semver.NewConstraint(c) + _, _ = NewConstraint(c) } } @@ -57,8 +55,8 @@ func BenchmarkNewConstraintUnion(b *testing.B) { func benchCheckVersion(c, v string, b *testing.B) { b.ReportAllocs() b.ResetTimer() - version, _ := semver.NewVersion(v) - constraint, _ := semver.NewConstraint(c) + version, _ := NewVersion(v) + constraint, _ := NewConstraint(c) for i := 0; i < b.N; i++ { constraint.Check(version) @@ -104,8 +102,8 @@ func BenchmarkCheckVersionUnion(b *testing.B) { func benchValidateVersion(c, v string, b *testing.B) { b.ReportAllocs() b.ResetTimer() - version, _ := semver.NewVersion(v) - constraint, _ := semver.NewConstraint(c) + version, _ := NewVersion(v) + constraint, _ := NewConstraint(c) for i := 0; i < b.N; i++ { constraint.Validate(version) @@ -190,13 +188,13 @@ func BenchmarkValidateVersionUnionFail(b *testing.B) { func benchNewVersion(v string, b *testing.B) { for i := 0; i < b.N; i++ { - _, _ = semver.NewVersion(v) + _, _ = NewVersion(v) } } func benchStrictNewVersion(v string, b *testing.B) { for i := 0; i < b.N; i++ { - _, _ = semver.StrictNewVersion(v) + _, _ = StrictNewVersion(v) } } diff --git a/go.mod b/go.mod index 4325780..658233c 100644 --- a/go.mod +++ b/go.mod @@ -1,3 +1,3 @@ -module github.com/Masterminds/semver +module github.com/Masterminds/semver/v3 go 1.12