Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/npm/cli.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGar <gar+gh@danger.computer>2022-03-30 17:09:57 +0300
committerLuke Karrys <luke@lukekarrys.com>2022-04-20 02:30:57 +0300
commit8da28b403f32d2e99c842893bdc40429b8ffa9a7 (patch)
tree17ab788fe15c80aa8e4074fd714183e17b47fe66 /tap-snapshots/test/lib
parentb06e89f434fe8f104e71d4d8b5c98f1e866efdfa (diff)
fix: remove lib/utils/read-package-name.js
This code wasn't doing anything special, just dereferencing `name` from a packument. There is no need for this to exist. Most of the tests were able to handle having this go away, except for `npm owner` which had to have its tests rewritten to be real, which of course surfaced bugs along the way of behavior that was incorrectly being tested. `npm owner` needs some love to clean up its UX, it throws or returns inconsistently. I did fix it so that if there is no package.json in cwd it errored as expected instead of throwing `ENOENT` which is what it did before.
Diffstat (limited to 'tap-snapshots/test/lib')
-rw-r--r--tap-snapshots/test/lib/commands/owner.js.test.cjs20
1 files changed, 0 insertions, 20 deletions
diff --git a/tap-snapshots/test/lib/commands/owner.js.test.cjs b/tap-snapshots/test/lib/commands/owner.js.test.cjs
deleted file mode 100644
index f3d7335e4..000000000
--- a/tap-snapshots/test/lib/commands/owner.js.test.cjs
+++ /dev/null
@@ -1,20 +0,0 @@
-/* IMPORTANT
- * This snapshot file is auto-generated, but designed for humans.
- * It should be checked into source control and tracked carefully.
- * Re-generate by setting TAP_SNAPSHOT=1 and running tests.
- * Make sure to inspect the output below. Do not ignore changes!
- */
-'use strict'
-exports[`test/lib/commands/owner.js TAP owner ls <pkg> > should output owners of <pkg> 1`] = `
-nlf <quitlahok@gmail.com>
-ruyadorno <ruyadorno@hotmail.com>
-darcyclarke <darcy@darcyclarke.me>
-isaacs <i@izs.me>
-`
-
-exports[`test/lib/commands/owner.js TAP owner ls no args > should output owners of cwd package 1`] = `
-nlf <quitlahok@gmail.com>
-ruyadorno <ruyadorno@hotmail.com>
-darcyclarke <darcy@darcyclarke.me>
-isaacs <i@izs.me>
-`