forked from yarnpkg/yarn
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix: respect patterns with "||" in the range during optimizeResolutio…
…ns (yarnpkg#4562) **Summary** Fixes yarnpkg#4547 by testing each version against all ranges individually, rather than munging the patterns together to get a single range. **Test plan** Existing tests, plus a regression test to repro yarnpkg#4547: "manifest optimization respects versions with alternation"
- Loading branch information
Showing
5 changed files
with
30 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
6 changes: 6 additions & 0 deletions
6
__tests__/fixtures/install/optimize-version-with-alternation/b/package.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
{ | ||
"version": "0.0.1", | ||
"dependencies": { | ||
"lodash": "^3.0.1 || ^2.0.0" | ||
} | ||
} |
6 changes: 6 additions & 0 deletions
6
__tests__/fixtures/install/optimize-version-with-alternation/package.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
{ | ||
"dependencies": { | ||
"b": "file:b", | ||
"lodash": "2.4.2" | ||
} | ||
} |
Binary file added
BIN
+193 KB
__tests__/fixtures/request-cache/GET/registry.yarnpkg.com/lodash/-/lodash-2.4.2.tgz.bin
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters