Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

constraintCaret broken #119

Closed
aaronbee opened this issue Sep 9, 2019 · 1 comment · Fixed by #120
Closed

constraintCaret broken #119

aaronbee opened this issue Sep 9, 2019 · 1 comment · Fixed by #120
Labels

Comments

@aaronbee
Copy link

aaronbee commented Sep 9, 2019

Commit 6e10208 broke constraintCaret. If the major version is greater than constraint major version and if some combination of minor or patch versions are equal, the constraint falsely passes. The following test case added to TestConstraintCheck reproduces the behavior.

		{"^1.1.0", "2.1.0", false},
		{"^1.2.0", "2.2.1", false},
--- FAIL: TestConstraintCheck (0.00s)
    constraints_test.go:197: Constraint "^1.0.0" failing with "2.1.0"
    constraints_test.go:197: Constraint "^1.2.0" failing with "2.2.1"
@mattfarina mattfarina added the bug label Sep 10, 2019
@mattfarina
Copy link
Member

I can confirm the bug and will have a fix out shortly. Thanks for reporting this.

mattfarina added a commit to mattfarina/semver that referenced this issue Sep 10, 2019
^ handling was not dealing with minor and patch versions properly.

Closes Masterminds#119
mattfarina added a commit to mattfarina/semver that referenced this issue Sep 10, 2019
^ handling was not dealing with minor and patch versions properly.

Closes Masterminds#119
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants