diff options
author | kumavis <aaron@kumavis.me> | 2021-02-22 09:16:02 +0300 |
---|---|---|
committer | Gar <gar+gh@danger.computer> | 2021-02-25 21:23:33 +0300 |
commit | 881a8558de5cb808c9efdcf3fb5d0a86a95e8eb0 (patch) | |
tree | 8ebce5fe9fb4528a35ad1d19d30867663abfe051 /tap-snapshots | |
parent | 28d036ae9179f742bd0518e558a54f014a7a895e (diff) |
feat(explain): mark when dependency is bundled
When using `npm explain <package>` it's useful to see if the package has
been bundled. This is especially useful when trying to understand the
provenance of a package's content
PR-URL: https://github.com/npm/cli/pull/2750
Credit: @kumavis
Close: #2750
Reviewed-by: @nlf
Diffstat (limited to 'tap-snapshots')
-rw-r--r-- | tap-snapshots/test-lib-utils-explain-dep.js-TAP.test.js | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/tap-snapshots/test-lib-utils-explain-dep.js-TAP.test.js b/tap-snapshots/test-lib-utils-explain-dep.js-TAP.test.js index 54a77bc12..6d169bca6 100644 --- a/tap-snapshots/test-lib-utils-explain-dep.js-TAP.test.js +++ b/tap-snapshots/test-lib-utils-explain-dep.js-TAP.test.js @@ -21,6 +21,28 @@ manydep@1.0.0 6 more (optdep, extra-neos, deep-dev, peer, the root project, a package with a pretty long name) ` +exports[`test/lib/utils/explain-dep.js TAP bundled > explain color deep 1`] = ` +[1mbundle-of-joy[22m@[1m1.0.0[22m [1m[34mbundled[39m[22m[2m[22m +[2mnode_modules/bundle-of-joy[22m + [1mprod-dep[22m@"[1m1.x[22m" from the root project +` + +exports[`test/lib/utils/explain-dep.js TAP bundled > explain nocolor shallow 1`] = ` +bundle-of-joy@1.0.0 bundled +node_modules/bundle-of-joy + prod-dep@"1.x" from the root project +` + +exports[`test/lib/utils/explain-dep.js TAP bundled > print color 1`] = ` +[1mbundle-of-joy[22m@[1m1.0.0[22m [1m[34mbundled[39m[22m[2m[22m +[2mnode_modules/bundle-of-joy[22m +` + +exports[`test/lib/utils/explain-dep.js TAP bundled > print nocolor 1`] = ` +bundle-of-joy@1.0.0 bundled +node_modules/bundle-of-joy +` + exports[`test/lib/utils/explain-dep.js TAP deepDev > explain color deep 1`] = ` [1mdeep-dev[22m@[1m2.3.4[22m [1m[33mdev[39m[22m[2m[22m [2mnode_modules/deep-dev[22m |