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

Add Exclusive prerelease specifier scenarios #172

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
52 changes: 52 additions & 0 deletions scenarios/prereleases.json
Original file line number Diff line number Diff line change
Expand Up @@ -169,6 +169,58 @@
"explanation": "Since the user provided a prerelease specifier, the latest prerelease version should be selected."
}
},
{
"name": "package-exclusive-ordered-comparison-prerelease-specified-mixed-available",
"description": "The user requires a version of `a` with an exclusive ordered comparison prerelease specifier and both prerelease and stable releases are available.",
"root": {
"requires": [
"a>0.1.0a1"
]
},
"packages": {
"a": {
"versions": {
"0.1.0": {},
"0.2.0a1": {},
"0.3.0": {},
"1.0.0a1": {}
}
}
},
"expected": {
"satisfiable": true,
"packages": {
"a": "1.0.0a1"
},
"explanation": "Since the user provided a prerelease specifier, the latest prerelease version should be selected, even though an exclusive ordered comparison was used."
}
},
{
"name": "package-not-equal-prerelease-specified-mixed-available",
"description": "The user requires a version of `a` which is not a specific prerelease version, and both prerelease and stable releases are available.",
"root": {
"requires": [
"a!=0.2.0a1"
]
},
"packages": {
"a": {
"versions": {
"0.1.0": {},
"0.2.0a1": {},
"0.3.0": {},
"1.0.0a1": {}
}
}
},
"expected": {
"satisfiable": true,
"packages": {
"a": "0.3.0"
},
"explanation": "Even though a prerelease specifier was given, it was '!=', which does not imply prereleases should be selected, therefore the latest final release should be chosen."
}
},
{
"name": "package-multiple-prereleases-kinds",
"description": "The user requires `a` which has multiple prereleases available with different labels.",
Expand Down