diff --git a/README.md b/README.md index 4b0d3e6..24be21a 100644 --- a/README.md +++ b/README.md @@ -147,6 +147,7 @@ The caret (`^`) comparison operator is for major level changes. This is useful when comparisons of API versions as a major change is API breaking. For example, * `^1.2.3` is equivalent to `>= 1.2.3, < 2.0.0` +* `^0.0.1` is equivalent to `>= 0.0.1, < 1.0.0` * `^1.2.x` is equivalent to `>= 1.2.0, < 2.0.0` * `^2.3` is equivalent to `>= 2.3, < 3` * `^2.x` is equivalent to `>= 2.0.0, < 3` diff --git a/constraints_test.go b/constraints_test.go index fed9329..ca9b691 100644 --- a/constraints_test.go +++ b/constraints_test.go @@ -354,6 +354,7 @@ func TestConstraintsValidate(t *testing.T) { {"^1.x", "1.1.1", true}, {"^2.x", "1.1.1", false}, {"^1.x", "2.1.1", false}, + {"^0.0.1", "0.1.3", true}, {"~*", "2.1.1", true}, {"~1", "2.1.1", false}, {"~1", "1.3.5", true},