Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore: add tests for moduleGraph2 (#23603)
Also did some renames from underscores to hyphens
- Loading branch information
Showing
37 changed files
with
127 additions
and
66 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
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 |
---|---|---|
@@ -1,13 +1,13 @@ | ||
Download http://127.0.0.1:4250/@denotest/deps/meta.json | ||
Download http://127.0.0.1:4250/@denotest/deps/1.0.0_meta.json | ||
Download http://127.0.0.1:4250/@denotest/module_graph/meta.json | ||
Download http://127.0.0.1:4250/@denotest/no_module_graph/meta.json | ||
Download http://127.0.0.1:4250/@denotest/module_graph/1.4.0_meta.json | ||
Download http://127.0.0.1:4250/@denotest/no_module_graph/0.1.1_meta.json | ||
Download http://127.0.0.1:4250/@denotest/module-graph/meta.json | ||
Download http://127.0.0.1:4250/@denotest/no-module-graph/meta.json | ||
Download http://127.0.0.1:4250/@denotest/module-graph/1.4.0_meta.json | ||
Download http://127.0.0.1:4250/@denotest/no-module-graph/0.1.1_meta.json | ||
[UNORDERED_START] | ||
Download http://127.0.0.1:4250/@denotest/deps/1.0.0/mod.ts | ||
Download http://127.0.0.1:4250/@denotest/module_graph/1.4.0/other.ts | ||
Download http://127.0.0.1:4250/@denotest/no_module_graph/0.1.1/mod.ts | ||
Download http://127.0.0.1:4250/@denotest/no_module_graph/0.1.1/TestClass.ts | ||
Download http://127.0.0.1:4250/@denotest/module-graph/1.4.0/other.ts | ||
Download http://127.0.0.1:4250/@denotest/no-module-graph/0.1.1/mod.ts | ||
Download http://127.0.0.1:4250/@denotest/no-module-graph/0.1.1/TestClass.ts | ||
[UNORDERED_END] | ||
{ version: "0.1.1", other: Other {} } |
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 |
---|---|---|
@@ -1,7 +1,5 @@ | ||
Download http://127.0.0.1:4250/@denotest/module_graph/meta.json | ||
Download http://127.0.0.1:4250/@denotest/module_graph/1.4.0_meta.json | ||
[UNORDERED_START] | ||
Download http://127.0.0.1:4250/@denotest/module_graph/1.4.0/other.ts | ||
Download http://127.0.0.1:4250/@denotest/module_graph/1.4.0/mod.ts | ||
[UNORDERED_END] | ||
[WILDCARD]Caching module info for http://[WILDLINE]/@denotest/module-graph/1.4.0/mod.ts | ||
[WILDCARD]Caching module info for http://[WILDLINE]/@denotest/module-graph/1.4.0/other.ts | ||
[WILDCARD] | ||
Test { other: Other {} } | ||
[WILDCARD] |
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 |
---|---|---|
@@ -1,3 +1,3 @@ | ||
import { Test } from "jsr:@denotest/module_graph"; | ||
import { Test } from "jsr:@denotest/module-graph"; | ||
|
||
console.log(new Test()); |
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 |
---|---|---|
@@ -1,14 +1,14 @@ | ||
Download http://127.0.0.1:4250/@denotest/module_graph/meta.json | ||
Download http://127.0.0.1:4250/@denotest/module_graph/1.4.0_meta.json | ||
Download http://127.0.0.1:4250/@denotest/module-graph/meta.json | ||
Download http://127.0.0.1:4250/@denotest/module-graph/1.4.0_meta.json | ||
[UNORDERED_START] | ||
Download http://127.0.0.1:4250/@denotest/module_graph/1.4.0/mod.ts | ||
Download http://127.0.0.1:4250/@denotest/module_graph/1.4.0/other.ts | ||
Download http://127.0.0.1:4250/@denotest/module-graph/1.4.0/mod.ts | ||
Download http://127.0.0.1:4250/@denotest/module-graph/1.4.0/other.ts | ||
[UNORDERED_END] | ||
local: [WILDCARD]main.ts | ||
type: TypeScript | ||
dependencies: 2 unique | ||
size: [WILDCARD] | ||
|
||
file:///[WILDCARD]/module_graph/main.ts ([WILDCARD]) | ||
└─┬ http://127.0.0.1:4250/@denotest/module_graph/1.4.0/mod.ts ([WILDCARD]) | ||
└── http://127.0.0.1:4250/@denotest/module_graph/1.4.0/other.ts ([WILDCARD]) | ||
└─┬ http://127.0.0.1:4250/@denotest/module-graph/1.4.0/mod.ts ([WILDCARD]) | ||
└── http://127.0.0.1:4250/@denotest/module-graph/1.4.0/other.ts ([WILDCARD]) |
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 |
---|---|---|
@@ -0,0 +1,10 @@ | ||
{ | ||
"steps": [{ | ||
"args": "run --log-level=debug main.ts", | ||
"output": "main.out" | ||
}, { | ||
"cleanDenoDir": true, | ||
"args": "info main.ts", | ||
"output": "main_info.out" | ||
}] | ||
} |
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 |
---|---|---|
@@ -0,0 +1,5 @@ | ||
[WILDCARD]Caching module info for http://[WILDLINE]/@denotest/module-graph2/1.4.0/mod.ts | ||
[WILDCARD]Caching module info for http://[WILDLINE]/@denotest/module-graph2/1.4.0/other.ts | ||
[WILDCARD] | ||
Test { other: Other {} } | ||
[WILDCARD] |
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 |
---|---|---|
@@ -0,0 +1,3 @@ | ||
import { Test } from "jsr:@denotest/module-graph2"; | ||
|
||
console.log(new Test()); |
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 |
---|---|---|
@@ -0,0 +1,14 @@ | ||
Download http://127.0.0.1:4250/@denotest/module-graph2/meta.json | ||
Download http://127.0.0.1:4250/@denotest/module-graph2/1.4.0_meta.json | ||
[UNORDERED_START] | ||
Download http://127.0.0.1:4250/@denotest/module-graph2/1.4.0/mod.ts | ||
Download http://127.0.0.1:4250/@denotest/module-graph2/1.4.0/other.ts | ||
[UNORDERED_END] | ||
local: [WILDCARD]main.ts | ||
type: TypeScript | ||
dependencies: 2 unique | ||
size: [WILDCARD] | ||
|
||
file:///[WILDCARD]/module_graph2/main.ts ([WILDCARD]) | ||
└─┬ http://127.0.0.1:4250/@denotest/module-graph2/1.4.0/mod.ts ([WILDCARD]) | ||
└── http://127.0.0.1:4250/@denotest/module-graph2/1.4.0/other.ts ([WILDCARD]) |
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 |
---|---|---|
@@ -1,6 +1,6 @@ | ||
Download http://127.0.0.1:4250/@denotest/no_module_graph/meta.json | ||
Download http://127.0.0.1:4250/@denotest/no_module_graph/0.1.0_meta.json | ||
Download http://127.0.0.1:4250/@denotest/no_module_graph/0.1.0/mod.ts | ||
Download http://127.0.0.1:4250/@denotest/no_module_graph/0.1.0/TestClass.ts | ||
Download http://127.0.0.1:4250/@denotest/no-module-graph/meta.json | ||
Download http://127.0.0.1:4250/@denotest/no-module-graph/0.1.0_meta.json | ||
Download http://127.0.0.1:4250/@denotest/no-module-graph/0.1.0/mod.ts | ||
Download http://127.0.0.1:4250/@denotest/no-module-graph/0.1.0/TestClass.ts | ||
0.1.0 | ||
TestClass {} |
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 |
---|---|---|
@@ -1,4 +1,4 @@ | ||
import version, { TestClass } from "jsr:@denotest/no_module_graph@0.1.0"; | ||
import version, { TestClass } from "jsr:@denotest/no-module-graph@0.1.0"; | ||
|
||
console.log(version); | ||
console.log(new TestClass()); |
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 |
---|---|---|
@@ -1,12 +1,12 @@ | ||
Download http://127.0.0.1:4250/@denotest/no_module_graph/meta.json | ||
Download http://127.0.0.1:4250/@denotest/no_module_graph/0.1.0_meta.json | ||
Download http://127.0.0.1:4250/@denotest/no_module_graph/0.1.0/mod.ts | ||
Download http://127.0.0.1:4250/@denotest/no_module_graph/0.1.0/TestClass.ts | ||
Download http://127.0.0.1:4250/@denotest/no-module-graph/meta.json | ||
Download http://127.0.0.1:4250/@denotest/no-module-graph/0.1.0_meta.json | ||
Download http://127.0.0.1:4250/@denotest/no-module-graph/0.1.0/mod.ts | ||
Download http://127.0.0.1:4250/@denotest/no-module-graph/0.1.0/TestClass.ts | ||
local: [WILDCARD]main.ts | ||
type: TypeScript | ||
dependencies: 2 unique | ||
size: [WILDCARD] | ||
|
||
file:///[WILDCARD]/jsr/no_module_graph/main.ts ([WILDCARD]) | ||
└─┬ http://127.0.0.1:4250/@denotest/no_module_graph/0.1.0/mod.ts ([WILDCARD]) | ||
└── http://127.0.0.1:4250/@denotest/no_module_graph/0.1.0/TestClass.ts ([WILDCARD]) | ||
└─┬ http://127.0.0.1:4250/@denotest/no-module-graph/0.1.0/mod.ts ([WILDCARD]) | ||
└── http://127.0.0.1:4250/@denotest/no-module-graph/0.1.0/TestClass.ts ([WILDCARD]) |
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 |
---|---|---|
@@ -1,5 +1,5 @@ | ||
import version1 from "jsr:@denotest/no_module_graph@0.1.0"; | ||
import version2 from "jsr:@denotest/no_module_graph@^0.2"; | ||
import version1 from "jsr:@denotest/no-module-graph@0.1.0"; | ||
import version2 from "jsr:@denotest/no-module-graph@^0.2"; | ||
|
||
console.log(version1); | ||
console.log(version2); |
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
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
5 changes: 5 additions & 0 deletions
5
tests/testdata/jsr/registry/@denotest/module-graph2/1.4.0/mod.ts
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 |
---|---|---|
@@ -0,0 +1,5 @@ | ||
import { Other } from "./other.ts"; | ||
|
||
export class Test { | ||
other = new Other(); | ||
} |
2 changes: 2 additions & 0 deletions
2
tests/testdata/jsr/registry/@denotest/module-graph2/1.4.0/other.ts
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 |
---|---|---|
@@ -0,0 +1,2 @@ | ||
export class Other { | ||
} |
17 changes: 17 additions & 0 deletions
17
tests/testdata/jsr/registry/@denotest/module-graph2/1.4.0_meta.json
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 |
---|---|---|
@@ -0,0 +1,17 @@ | ||
{ | ||
"exports": { | ||
".": "./mod.ts", | ||
"./other": "./other.ts" | ||
}, | ||
"moduleGraph2": { | ||
"/mod.ts": { | ||
"dependencies": [{ | ||
"kind": "import", | ||
"type": "static", | ||
"specifier": "./other.ts", | ||
"specifierRange": [[0, 22], [0, 34]] | ||
}] | ||
}, | ||
"/other.ts": {} | ||
} | ||
} |
6 changes: 6 additions & 0 deletions
6
tests/testdata/jsr/registry/@denotest/module-graph2/meta.json
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 |
---|---|---|
@@ -0,0 +1,6 @@ | ||
{ | ||
"versions": { | ||
"1.0.0": {}, | ||
"1.4.0": {} | ||
} | ||
} |
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.