Skip to content

Commit

Permalink
test: assert semvers are *not* compared lexically
Browse files Browse the repository at this point in the history
  • Loading branch information
schmichael committed Nov 19, 2019
1 parent 88a9877 commit ecd4ed1
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions helper/constraints/semver/constraints_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,9 @@ func TestConstraintCheck(t *testing.T) {
{"= 1.0", "1.0.0", true},
{"1.0", "1.0.0", true},

// Assert numbers are *not* compared lexically as in #4729
{"> 10", "8", false},

// Pre-releases are ordered according to Semver v2
{"> 2.0", "2.1.0-beta", true},
{"> 2.1.0-a", "2.1.0-beta", true},
Expand Down

0 comments on commit ecd4ed1

Please sign in to comment.