-
Notifications
You must be signed in to change notification settings - Fork 3.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: add package-lock-only mode to npm query
- Loading branch information
Showing
5 changed files
with
128 additions
and
2 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
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
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 |
---|---|---|
|
@@ -99,6 +99,54 @@ exports[`test/lib/commands/query.js TAP linked node > should return linked node | |
] | ||
` | ||
|
||
exports[`test/lib/commands/query.js TAP package-lock-only with package lock > should return valid response with only lock info 1`] = ` | ||
[ | ||
{ | ||
"name": "project", | ||
"dependencies": { | ||
"a": "^1.0.0" | ||
}, | ||
"pkgid": "project@", | ||
"location": "", | ||
"path": "{CWD}/prefix", | ||
"realpath": "{CWD}/prefix", | ||
"resolved": null, | ||
"from": [], | ||
"to": [ | ||
"node_modules/a" | ||
], | ||
"dev": false, | ||
"inBundle": false, | ||
"deduped": false, | ||
"overridden": false, | ||
"queryContext": {} | ||
}, | ||
{ | ||
"version": "1.2.3", | ||
"resolved": "https://dummy.npmjs.org/a/-/a-1.2.3.tgz", | ||
"integrity": "sha512-dummy", | ||
"engines": { | ||
"node": ">=14.17" | ||
}, | ||
"name": "a", | ||
"_id": "[email protected]", | ||
"pkgid": "[email protected]", | ||
"location": "node_modules/a", | ||
"path": "{CWD}/prefix/node_modules/a", | ||
"realpath": "{CWD}/prefix/node_modules/a", | ||
"from": [ | ||
"" | ||
], | ||
"to": [], | ||
"dev": false, | ||
"inBundle": false, | ||
"deduped": false, | ||
"overridden": false, | ||
"queryContext": {} | ||
} | ||
] | ||
` | ||
|
||
exports[`test/lib/commands/query.js TAP recursive tree > should return everything in the tree, accounting for recursion 1`] = ` | ||
[ | ||
{ | ||
|
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
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