diff options
Diffstat (limited to 'cli/tests/testdata/npm')
11 files changed, 55 insertions, 50 deletions
diff --git a/cli/tests/testdata/npm/cached_only/main.out b/cli/tests/testdata/npm/cached_only/main.out index f49494839..d03420fee 100644 --- a/cli/tests/testdata/npm/cached_only/main.out +++ b/cli/tests/testdata/npm/cached_only/main.out @@ -1,4 +1,2 @@ -error: Error getting response at http://localhost:4545/npm/registry/chalk for package "chalk" - -Caused by: - An npm specifier not found in cache: "chalk", --cached-only is specified. +error: Error getting response at http://localhost:4545/npm/registry/chalk for package "chalk": An npm specifier not found in cache: "chalk", --cached-only is specified. + at file:///[WILDCARD]/testdata/npm/cached_only/main.ts:1:19 diff --git a/cli/tests/testdata/npm/cjs_with_deps/main.out b/cli/tests/testdata/npm/cjs_with_deps/main.out index 23c217f7a..3a16ff467 100644 --- a/cli/tests/testdata/npm/cjs_with_deps/main.out +++ b/cli/tests/testdata/npm/cjs_with_deps/main.out @@ -1,5 +1,7 @@ -Download http://localhost:4545/npm/registry/chai Download http://localhost:4545/npm/registry/chalk +Download http://localhost:4545/npm/registry/chai +Download http://localhost:4545/npm/registry/ansi-styles +Download http://localhost:4545/npm/registry/supports-color Download http://localhost:4545/npm/registry/assertion-error Download http://localhost:4545/npm/registry/check-error Download http://localhost:4545/npm/registry/deep-eql @@ -7,8 +9,6 @@ Download http://localhost:4545/npm/registry/get-func-name Download http://localhost:4545/npm/registry/loupe Download http://localhost:4545/npm/registry/pathval Download http://localhost:4545/npm/registry/type-detect -Download http://localhost:4545/npm/registry/ansi-styles -Download http://localhost:4545/npm/registry/supports-color Download http://localhost:4545/npm/registry/color-convert Download http://localhost:4545/npm/registry/has-flag Download http://localhost:4545/npm/registry/color-name diff --git a/cli/tests/testdata/npm/cjs_with_deps/main_info.out b/cli/tests/testdata/npm/cjs_with_deps/main_info.out index 345583a90..cf84197e1 100644 --- a/cli/tests/testdata/npm/cjs_with_deps/main_info.out +++ b/cli/tests/testdata/npm/cjs_with_deps/main_info.out @@ -4,19 +4,19 @@ dependencies: 14 unique size: [WILDCARD] file:///[WILDCARD]/npm/cjs_with_deps/main.js ([WILDCARD]) -├─┬ npm:chai@4.3 - 4.3.6 ([WILDCARD]) -│ ├── npm:assertion-error@1.1.0 ([WILDCARD]) -│ ├── npm:check-error@1.0.2 ([WILDCARD]) -│ ├─┬ npm:deep-eql@3.0.1 ([WILDCARD]) -│ │ └── npm:type-detect@4.0.8 ([WILDCARD]) -│ ├── npm:get-func-name@2.0.0 ([WILDCARD]) -│ ├─┬ npm:loupe@2.3.4 ([WILDCARD]) -│ │ └── npm:get-func-name@2.0.0 ([WILDCARD]) -│ ├── npm:pathval@1.1.1 ([WILDCARD]) -│ └── npm:type-detect@4.0.8 ([WILDCARD]) -└─┬ npm:chalk@4 - 4.1.2 ([WILDCARD]) - ├─┬ npm:ansi-styles@4.3.0 ([WILDCARD]) - │ └─┬ npm:color-convert@2.0.1 ([WILDCARD]) - │ └── npm:color-name@1.1.4 ([WILDCARD]) - └─┬ npm:supports-color@7.2.0 ([WILDCARD]) - └── npm:has-flag@4.0.0 ([WILDCARD]) +├─┬ npm:chalk@4.1.2 ([WILDCARD]) +│ ├─┬ npm:ansi-styles@4.3.0 ([WILDCARD]) +│ │ └─┬ npm:color-convert@2.0.1 ([WILDCARD]) +│ │ └── npm:color-name@1.1.4 ([WILDCARD]) +│ └─┬ npm:supports-color@7.2.0 ([WILDCARD]) +│ └── npm:has-flag@4.0.0 ([WILDCARD]) +└─┬ npm:chai@4.3.6 ([WILDCARD]) + ├── npm:assertion-error@1.1.0 ([WILDCARD]) + ├── npm:check-error@1.0.2 ([WILDCARD]) + ├─┬ npm:deep-eql@3.0.1 ([WILDCARD]) + │ └── npm:type-detect@4.0.8 ([WILDCARD]) + ├── npm:get-func-name@2.0.0 ([WILDCARD]) + ├─┬ npm:loupe@2.3.4 ([WILDCARD]) + │ └── npm:get-func-name@2.0.0 ([WILDCARD]) + ├── npm:pathval@1.1.1 ([WILDCARD]) + └── npm:type-detect@4.0.8 ([WILDCARD]) diff --git a/cli/tests/testdata/npm/cjs_with_deps/main_info_json.out b/cli/tests/testdata/npm/cjs_with_deps/main_info_json.out index bc7b9e162..e2a659a42 100644 --- a/cli/tests/testdata/npm/cjs_with_deps/main_info_json.out +++ b/cli/tests/testdata/npm/cjs_with_deps/main_info_json.out @@ -4,43 +4,43 @@ ], "modules": [ { + "kind": "esm", "dependencies": [ { - "specifier": "npm:chai@4.3", + "specifier": "npm:chalk@4", "code": { - "specifier": "npm:chai@4.3", + "specifier": "npm:chalk@4", "span": { "start": { - "line": 1, - "character": 23 + "line": 0, + "character": 18 }, "end": { - "line": 1, - "character": 37 + "line": 0, + "character": 31 } } }, - "npmPackage": "chai@4.3.6" + "npmPackage": "chalk@4.1.2" }, { - "specifier": "npm:chalk@4", + "specifier": "npm:chai@4.3", "code": { - "specifier": "npm:chalk@4", + "specifier": "npm:chai@4.3", "span": { "start": { - "line": 0, - "character": 18 + "line": 1, + "character": 23 }, "end": { - "line": 0, - "character": 31 + "line": 1, + "character": 37 } } }, - "npmPackage": "chalk@4.1.2" + "npmPackage": "chai@4.3.6" } ], - "kind": "esm", "local": "[WILDCARD]main.js", "emit": null, "map": null, @@ -49,7 +49,10 @@ "specifier": "[WILDCARD]/main.js" } ], - "redirects": {}, + "redirects": { + "npm:chai@4.3": "npm:chai@4.3.6", + "npm:chalk@4": "npm:chalk@4.1.2" + }, "npmPackages": { "ansi-styles@4.3.0": { "name": "ansi-styles", diff --git a/cli/tests/testdata/npm/compare_globals/main.out b/cli/tests/testdata/npm/compare_globals/main.out index e60a39ba6..286834168 100644 --- a/cli/tests/testdata/npm/compare_globals/main.out +++ b/cli/tests/testdata/npm/compare_globals/main.out @@ -1,5 +1,5 @@ -Download http://localhost:4545/npm/registry/@denotest/globals Download http://localhost:4545/npm/registry/@types/node +Download http://localhost:4545/npm/registry/@denotest/globals Download http://localhost:4545/npm/registry/@denotest/globals/1.0.0.tgz Download http://localhost:4545/npm/registry/@types/node/node-18.8.2.tgz Check file:///[WILDCARD]/npm/compare_globals/main.ts diff --git a/cli/tests/testdata/npm/import_map/main.out b/cli/tests/testdata/npm/import_map/main.out index b5b67651e..29f0f4283 100644 --- a/cli/tests/testdata/npm/import_map/main.out +++ b/cli/tests/testdata/npm/import_map/main.out @@ -1,5 +1,5 @@ -Download http://localhost:4545/npm/registry/@denotest/dual-cjs-esm Download http://localhost:4545/npm/registry/chalk +Download http://localhost:4545/npm/registry/@denotest/dual-cjs-esm Download http://localhost:4545/npm/registry/@denotest/dual-cjs-esm/1.0.0.tgz Download http://localhost:4545/npm/registry/chalk/chalk-5.0.1.tgz chalk import map loads diff --git a/cli/tests/testdata/npm/info/chalk.out b/cli/tests/testdata/npm/info/chalk.out index 89ea05e71..d7ac95120 100644 --- a/cli/tests/testdata/npm/info/chalk.out +++ b/cli/tests/testdata/npm/info/chalk.out @@ -1,8 +1,7 @@ -type: Unknown dependencies: 5 unique size: [WILDCARD] -npm:chalk@4 - 4.1.2 ([WILDCARD]) +npm:chalk@4.1.2 ([WILDCARD]) ├─┬ npm:ansi-styles@4.3.0 ([WILDCARD]) │ └─┬ npm:color-convert@2.0.1 ([WILDCARD]) │ └── npm:color-name@1.1.4 ([WILDCARD]) diff --git a/cli/tests/testdata/npm/info/chalk_json.out b/cli/tests/testdata/npm/info/chalk_json.out index f6673d032..0f86bc994 100644 --- a/cli/tests/testdata/npm/info/chalk_json.out +++ b/cli/tests/testdata/npm/info/chalk_json.out @@ -5,11 +5,13 @@ "modules": [ { "kind": "npm", - "specifier": "npm:chalk@4", + "specifier": "npm:chalk@4.1.2", "npmPackage": "chalk@4.1.2" } ], - "redirects": {}, + "redirects": { + "npm:chalk@4": "npm:chalk@4.1.2" + }, "npmPackages": { "ansi-styles@4.3.0": { "name": "ansi-styles", diff --git a/cli/tests/testdata/npm/peer_deps_with_copied_folders/main_info.out b/cli/tests/testdata/npm/peer_deps_with_copied_folders/main_info.out index c9c4a59c1..d85b00094 100644 --- a/cli/tests/testdata/npm/peer_deps_with_copied_folders/main_info.out +++ b/cli/tests/testdata/npm/peer_deps_with_copied_folders/main_info.out @@ -4,11 +4,11 @@ dependencies: 6 unique size: [WILDCARD] file:///[WILDCARD]/testdata/npm/peer_deps_with_copied_folders/main.ts (171B) -├─┬ npm:@denotest/peer-dep-test-child@1 - 1.0.0 ([WILDCARD]) +├─┬ npm:@denotest/peer-dep-test-child@1.0.0 ([WILDCARD]) │ ├─┬ npm:@denotest/peer-dep-test-grandchild@1.0.0_@denotest+peer-dep-test-peer@1.0.0 ([WILDCARD]) │ │ └── npm:@denotest/peer-dep-test-peer@1.0.0 ([WILDCARD]) │ └── npm:@denotest/peer-dep-test-peer@1.0.0 ([WILDCARD]) -└─┬ npm:@denotest/peer-dep-test-child@2 - 2.0.0 ([WILDCARD]) +└─┬ npm:@denotest/peer-dep-test-child@2.0.0 ([WILDCARD]) ├─┬ npm:@denotest/peer-dep-test-grandchild@1.0.0_@denotest+peer-dep-test-peer@2.0.0 ([WILDCARD]) │ └── npm:@denotest/peer-dep-test-peer@2.0.0 ([WILDCARD]) └── npm:@denotest/peer-dep-test-peer@2.0.0 ([WILDCARD]) diff --git a/cli/tests/testdata/npm/peer_deps_with_copied_folders/main_info_json.out b/cli/tests/testdata/npm/peer_deps_with_copied_folders/main_info_json.out index 634ec6251..6a455b001 100644 --- a/cli/tests/testdata/npm/peer_deps_with_copied_folders/main_info_json.out +++ b/cli/tests/testdata/npm/peer_deps_with_copied_folders/main_info_json.out @@ -4,6 +4,7 @@ ], "modules": [ { + "kind": "esm", "dependencies": [ { "specifier": "npm:@denotest/peer-dep-test-child@1", @@ -40,7 +41,6 @@ "npmPackage": "@denotest/peer-dep-test-child@2.0.0_@denotest+peer-dep-test-peer@2.0.0" } ], - "kind": "esm", "local": "[WILDCARD]main.ts", "emit": null, "map": null, @@ -49,7 +49,10 @@ "specifier": "file://[WILDCARD]/main.ts" } ], - "redirects": {}, + "redirects": { + "npm:@denotest/peer-dep-test-child@1": "npm:@denotest/peer-dep-test-child@1.0.0", + "npm:@denotest/peer-dep-test-child@2": "npm:@denotest/peer-dep-test-child@2.0.0" + }, "npmPackages": { "@denotest/peer-dep-test-child@1.0.0_@denotest+peer-dep-test-peer@1.0.0": { "name": "@denotest/peer-dep-test-child", diff --git a/cli/tests/testdata/npm/typescript_file_in_package/main.out b/cli/tests/testdata/npm/typescript_file_in_package/main.out index ba53f7725..0d6f53cd9 100644 --- a/cli/tests/testdata/npm/typescript_file_in_package/main.out +++ b/cli/tests/testdata/npm/typescript_file_in_package/main.out @@ -1,6 +1,6 @@ Download http://localhost:4545/npm/registry/@denotest/typescript-file Download http://localhost:4545/npm/registry/@denotest/typescript-file/1.0.0.tgz -error: Could not resolve 'npm:@denotest/typescript-file'. +error: Could not resolve 'npm:@denotest/typescript-file@1.0.0'. Caused by: TypeScript files are not supported in npm packages: file:///[WILDCARD]/@denotest/typescript-file/1.0.0/index.ts |
