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:
Diffstat (limited to 'tap-snapshots/test/lib/view.js.test.cjs')
-rw-r--r--tap-snapshots/test/lib/view.js.test.cjs529
1 files changed, 529 insertions, 0 deletions
diff --git a/tap-snapshots/test/lib/view.js.test.cjs b/tap-snapshots/test/lib/view.js.test.cjs
new file mode 100644
index 000000000..1cdf35635
--- /dev/null
+++ b/tap-snapshots/test/lib/view.js.test.cjs
@@ -0,0 +1,529 @@
+/* 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/view.js TAP should log info by field name array field - 1 element > must match snapshot 1`] = `
+
+claudia
+`
+
+exports[`test/lib/view.js TAP should log info by field name array field - 2 elements > must match snapshot 1`] = `
+
+maintainers[0].name = 'claudia'
+maintainers[1].name = 'isaacs'
+`
+
+exports[`test/lib/view.js TAP should log info by field name maintainers with email > must match snapshot 1`] = `
+
+{
+ "maintainers": [
+ {
+ "name": "claudia",
+ "email": "c@yellow.com",
+ "twitter": "cyellow"
+ },
+ {
+ "name": "isaacs",
+ "email": "i@yellow.com",
+ "twitter": "iyellow"
+ }
+ ],
+ "name": "yellow"
+}
+`
+
+exports[`test/lib/view.js TAP should log info by field name maintainers with url > must match snapshot 1`] = `
+
+[
+ "claudia (http://c.pink.com)",
+ "isaacs (http://i.pink.com)"
+]
+`
+
+exports[`test/lib/view.js TAP should log info by field name nested field with brackets > must match snapshot 1`] = `
+
+"123"
+`
+
+exports[`test/lib/view.js TAP should log info by field name readme > must match snapshot 1`] = `
+
+a very useful readme
+`
+
+exports[`test/lib/view.js TAP should log info by field name several fields > must match snapshot 1`] = `
+
+{
+ "name": "yellow",
+ "version": "1.0.0"
+}
+`
+
+exports[`test/lib/view.js TAP should log info by field name several fields with several versions > must match snapshot 1`] = `
+
+yellow@1.0.0 'claudia'
+yellow@1.0.1 'claudia'
+yellow@1.0.2 'claudia'
+`
+
+exports[`test/lib/view.js TAP should log info of package in current working dir non-specific version > must match snapshot 1`] = `
+
+
+blue@1.0.0 | Proprietary | deps: none | versions: 2
+
+dist
+.tarball:http://hm.blue.com/1.0.0.tgz
+.shasum:123
+.integrity:---
+.unpackedSize:1 B
+
+dist-tags:
+
+
+published a year ago
+`
+
+exports[`test/lib/view.js TAP should log info of package in current working dir specific version > must match snapshot 1`] = `
+
+
+blue@1.0.0 | Proprietary | deps: none | versions: 2
+
+dist
+.tarball:http://hm.blue.com/1.0.0.tgz
+.shasum:123
+.integrity:---
+.unpackedSize:1 B
+
+dist-tags:
+
+
+published a year ago
+`
+
+exports[`test/lib/view.js TAP should log package info package with --json and semver range > must match snapshot 1`] = `
+
+[
+ {
+ "_npmUser": "claudia <claudia@cyan.com>",
+ "name": "cyan",
+ "dist-tags": {},
+ "versions": [
+ "1.0.0",
+ "1.0.1"
+ ],
+ "version": "1.0.0",
+ "dist": {
+ "shasum": "123",
+ "tarball": "http://hm.cyan.com/1.0.0.tgz",
+ "integrity": "---",
+ "fileCount": 1,
+ "unpackedSize": 1
+ }
+ },
+ {
+ "_npmUser": "claudia <claudia@cyan.com>",
+ "name": "cyan",
+ "dist-tags": {},
+ "versions": [
+ "1.0.0",
+ "1.0.1"
+ ]
+ }
+]
+`
+
+exports[`test/lib/view.js TAP should log package info package with homepage > must match snapshot 1`] = `
+
+
+orange@1.0.0 | Proprietary | deps: none | versions: 2
+http://hm.orange.com
+
+dist
+.tarball:http://hm.orange.com/1.0.0.tgz
+.shasum:123
+.integrity:---
+.unpackedSize:1 B
+
+dist-tags:
+latest: 1.0.0
+`
+
+exports[`test/lib/view.js TAP should log package info package with license, bugs, repository and other fields > must match snapshot 1`] = `
+
+
+green@1.0.0 | ACME | deps: 2 | versions: 2
+green is a very important color
+
+DEPRECATED!! - true
+
+keywords:colors, green, crayola
+
+bin:green
+
+dist
+.tarball:http://hm.green.com/1.0.0.tgz
+.shasum:123
+.integrity:---
+.unpackedSize:1 B
+
+dependencies:
+red: 1.0.0
+yellow: 1.0.0
+
+maintainers:
+-claudia <c@yellow.com>
+-isaacs <i@yellow.com>
+
+dist-tags:
+latest: 1.0.0
+`
+
+exports[`test/lib/view.js TAP should log package info package with maintainers info as object > must match snapshot 1`] = `
+
+
+pink@1.0.0 | Proprietary | deps: none | versions: 2
+
+dist
+.tarball:http://hm.pink.com/1.0.0.tgz
+.shasum:123
+.integrity:---
+.unpackedSize:1 B
+
+dist-tags:
+latest: 1.0.0
+`
+
+exports[`test/lib/view.js TAP should log package info package with more than 25 deps > must match snapshot 1`] = `
+
+
+black@1.0.0 | Proprietary | deps: 25 | versions: 2
+
+dist
+.tarball:http://hm.black.com/1.0.0.tgz
+.shasum:123
+.integrity:---
+.unpackedSize:1 B
+
+dependencies:
+0: 1.0.0
+10: 1.0.0
+11: 1.0.0
+12: 1.0.0
+13: 1.0.0
+14: 1.0.0
+15: 1.0.0
+16: 1.0.0
+17: 1.0.0
+18: 1.0.0
+19: 1.0.0
+1: 1.0.0
+20: 1.0.0
+21: 1.0.0
+22: 1.0.0
+23: 1.0.0
+2: 1.0.0
+3: 1.0.0
+4: 1.0.0
+5: 1.0.0
+6: 1.0.0
+7: 1.0.0
+8: 1.0.0
+9: 1.0.0
+(...and 1 more.)
+
+dist-tags:
+latest: 1.0.0
+`
+
+exports[`test/lib/view.js TAP should log package info package with no modified time > must match snapshot 1`] = `
+
+
+cyan@1.0.0 | Proprietary | deps: none | versions: 2
+
+dist
+.tarball:http://hm.cyan.com/1.0.0.tgz
+.shasum:123
+.integrity:---
+.unpackedSize:1 B
+
+dist-tags:
+
+
+published by claudia <claudia@cyan.com>
+`
+
+exports[`test/lib/view.js TAP should log package info package with no repo or homepage > must match snapshot 1`] = `
+
+
+blue@1.0.0 | Proprietary | deps: none | versions: 2
+
+dist
+.tarball:http://hm.blue.com/1.0.0.tgz
+.shasum:123
+.integrity:---
+.unpackedSize:1 B
+
+dist-tags:
+
+
+published a year ago
+`
+
+exports[`test/lib/view.js TAP workspaces all workspaces --json > must match snapshot 1`] = `
+
+{
+ "green": {
+ "_id": "green",
+ "name": "green",
+ "dist-tags": {
+ "latest": "1.0.0"
+ },
+ "maintainers": [
+ {
+ "name": "claudia",
+ "email": "c@yellow.com",
+ "twitter": "cyellow"
+ },
+ {
+ "name": "isaacs",
+ "email": "i@yellow.com",
+ "twitter": "iyellow"
+ }
+ ],
+ "keywords": [
+ "colors",
+ "green",
+ "crayola"
+ ],
+ "versions": [
+ "1.0.0",
+ "1.0.1"
+ ],
+ "version": "1.0.0",
+ "description": "green is a very important color",
+ "bugs": {
+ "url": "http://bugs.green.com"
+ },
+ "deprecated": true,
+ "repository": {
+ "url": "http://repository.green.com"
+ },
+ "license": {
+ "type": "ACME"
+ },
+ "bin": {
+ "green": "bin/green.js"
+ },
+ "dependencies": {
+ "red": "1.0.0",
+ "yellow": "1.0.0"
+ },
+ "dist": {
+ "shasum": "123",
+ "tarball": "http://hm.green.com/1.0.0.tgz",
+ "integrity": "---",
+ "fileCount": 1,
+ "unpackedSize": 1
+ }
+ },
+ "orange": {
+ "name": "orange",
+ "dist-tags": {
+ "latest": "1.0.0"
+ },
+ "versions": [
+ "1.0.0",
+ "1.0.1"
+ ],
+ "version": "1.0.0",
+ "homepage": "http://hm.orange.com",
+ "license": {},
+ "dist": {
+ "shasum": "123",
+ "tarball": "http://hm.orange.com/1.0.0.tgz",
+ "integrity": "---",
+ "fileCount": 1,
+ "unpackedSize": 1
+ }
+ }
+}
+`
+
+exports[`test/lib/view.js TAP workspaces all workspaces > must match snapshot 1`] = `
+
+
+green@1.0.0 | ACME | deps: 2 | versions: 2
+green is a very important color
+
+DEPRECATED!! - true
+
+keywords:colors, green, crayola
+
+bin:green
+
+dist
+.tarball:http://hm.green.com/1.0.0.tgz
+.shasum:123
+.integrity:---
+.unpackedSize:1 B
+
+dependencies:
+red: 1.0.0
+yellow: 1.0.0
+
+maintainers:
+-claudia <c@yellow.com>
+-isaacs <i@yellow.com>
+
+dist-tags:
+latest: 1.0.0
+
+orange@1.0.0 | Proprietary | deps: none | versions: 2
+http://hm.orange.com
+
+dist
+.tarball:http://hm.orange.com/1.0.0.tgz
+.shasum:123
+.integrity:---
+.unpackedSize:1 B
+
+dist-tags:
+latest: 1.0.0
+`
+
+exports[`test/lib/view.js TAP workspaces all workspaces nonexistent field --json > must match snapshot 1`] = `
+
+`
+
+exports[`test/lib/view.js TAP workspaces all workspaces nonexistent field > must match snapshot 1`] = `
+
+green:
+orange:
+`
+
+exports[`test/lib/view.js TAP workspaces all workspaces single field --json > must match snapshot 1`] = `
+
+{
+ "green": "green",
+ "orange": "orange"
+}
+`
+
+exports[`test/lib/view.js TAP workspaces all workspaces single field > must match snapshot 1`] = `
+
+green:
+green
+orange:
+orange
+`
+
+exports[`test/lib/view.js TAP workspaces one specific workspace > must match snapshot 1`] = `
+
+
+green@1.0.0 | ACME | deps: 2 | versions: 2
+green is a very important color
+
+DEPRECATED!! - true
+
+keywords:colors, green, crayola
+
+bin:green
+
+dist
+.tarball:http://hm.green.com/1.0.0.tgz
+.shasum:123
+.integrity:---
+.unpackedSize:1 B
+
+dependencies:
+red: 1.0.0
+yellow: 1.0.0
+
+maintainers:
+-claudia <c@yellow.com>
+-isaacs <i@yellow.com>
+
+dist-tags:
+latest: 1.0.0
+`
+
+exports[`test/lib/view.js TAP workspaces remote package name > must match snapshot 1`] = `
+Ignoring workspaces for specified package(s)
+`
+
+exports[`test/lib/view.js TAP workspaces remote package name > must match snapshot 2`] = `
+
+
+pink@1.0.0 | Proprietary | deps: none | versions: 2
+
+dist
+.tarball:http://hm.pink.com/1.0.0.tgz
+.shasum:123
+.integrity:---
+.unpackedSize:1 B
+
+dist-tags:
+latest: 1.0.0
+`
+
+exports[`test/lib/view.js TAP workspaces single workspace --json > must match snapshot 1`] = `
+
+{
+ "green": {
+ "_id": "green",
+ "name": "green",
+ "dist-tags": {
+ "latest": "1.0.0"
+ },
+ "maintainers": [
+ {
+ "name": "claudia",
+ "email": "c@yellow.com",
+ "twitter": "cyellow"
+ },
+ {
+ "name": "isaacs",
+ "email": "i@yellow.com",
+ "twitter": "iyellow"
+ }
+ ],
+ "keywords": [
+ "colors",
+ "green",
+ "crayola"
+ ],
+ "versions": [
+ "1.0.0",
+ "1.0.1"
+ ],
+ "version": "1.0.0",
+ "description": "green is a very important color",
+ "bugs": {
+ "url": "http://bugs.green.com"
+ },
+ "deprecated": true,
+ "repository": {
+ "url": "http://repository.green.com"
+ },
+ "license": {
+ "type": "ACME"
+ },
+ "bin": {
+ "green": "bin/green.js"
+ },
+ "dependencies": {
+ "red": "1.0.0",
+ "yellow": "1.0.0"
+ },
+ "dist": {
+ "shasum": "123",
+ "tarball": "http://hm.green.com/1.0.0.tgz",
+ "integrity": "---",
+ "fileCount": 1,
+ "unpackedSize": 1
+ }
+ }
+}
+`