Open
Description
hi, i want to exclude all the versions in 1.1.x
and set a range like this "!=1.1.x"
,but all the versions are checked failure.
Here's the test code.
import (
"github.com/blang/semver/v4"
"testing"
)
func TestV(t *testing.T) {
versionRange := "!=1.0.x"
expectedRange, err := semver.ParseRange(versionRange)
if err != nil { //wrong range exp
t.Fail()
}
v, _ := semver.Parse("1.1.1")
if !expectedRange(v) { // expectedRange(v) == false,want true but got false
t.Fail()
}
}
I noticed that this range will expand to <1.1.0 and >=1.2.0
,and it should link with OR
but not AND
.
Is there any plan to fix it ?
Metadata
Metadata
Assignees
Labels
No labels