Skip to content

Commit d95b86d

Browse files
committed
chore: clean up tests
1 parent 507ed36 commit d95b86d

File tree

10 files changed

+49
-57
lines changed

10 files changed

+49
-57
lines changed

Cargo.lock

Lines changed: 18 additions & 30 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ repository = "https://github.com/denoland/deno"
6161

6262
[workspace.dependencies]
6363
deno_ast = { version = "=0.50.3", features = ["transpiling"] }
64-
deno_core = { version = "0.368.0" }
64+
deno_core = { version = "0.369.0" }
6565

6666
deno_cache_dir = "=0.25.0"
6767
deno_doc = "=0.186.0"

cli/module_loader.rs

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1259,7 +1259,15 @@ impl<TGraphContainer: ModuleGraphContainer> ModuleLoader
12591259
let code = match graph.get(&specifier) {
12601260
Some(deno_graph::Module::Js(module)) => &module.source.text,
12611261
Some(deno_graph::Module::Json(module)) => &module.source.text,
1262-
_ => {
1262+
Some(
1263+
deno_graph::Module::Wasm(_)
1264+
| deno_graph::Module::Npm(_)
1265+
| deno_graph::Module::Node(_)
1266+
| deno_graph::Module::External(_),
1267+
) => {
1268+
return None;
1269+
}
1270+
None => {
12631271
// Not in graph, try to read from file system (for source-mapped original files)
12641272
if let Ok(Some(file)) = self
12651273
.0

tests/specs/run/sourcemap_external/external.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

tests/specs/run/sourcemap_external/external.js.map

Lines changed: 1 addition & 7 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
[WILDCARD]error: Uncaught[WILDCARD] Error: Test error with external sourcemap
2-
[WILDCARD]throw new Error("Test error with external sourcemap");
3-
[WILDCARD]^
4-
[WILDCARD]at throwError ([WILDCARD]original.ts:3:[WILDCARD]
5-
[WILDCARD]at [WILDCARD]original.ts:6:[WILDCARD]
1+
error: Uncaught (in promise) Error: Test error with external sourcemap
2+
throw new Error("Test error with external sourcemap");
3+
^
4+
at throwError ([WILDCARD]original.ts:3:3)
5+
at [WILDCARD]original.ts:6:14
Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
1-
[WILDCARD]error: Uncaught[WILDCARD] Error: Test error from inline sourcemap
2-
[WILDCARD]at throwError ([WILDCARD]test.ts:3:[WILDCARD]
3-
[WILDCARD]at [WILDCARD]test.ts:6:[WILDCARD]
1+
error: Uncaught (in promise) Error: Test error from inline sourcemap
2+
at throwError (file:///test.ts:3:1)
3+
at file:///test.ts:6:1
Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1-
[WILDCARD]error: Uncaught[WILDCARD] Error: Test error without sourcemap
2-
[WILDCARD]at throwError ([WILDCARD]no_sourcemap.js:3:[WILDCARD]
3-
[WILDCARD]at [WILDCARD]no_sourcemap.js:6:[WILDCARD]
1+
error: Uncaught (in promise) Error: Test error without sourcemap
2+
throw new Error("Test error without sourcemap");
3+
^
4+
at throwError (file:///[WILDCARD]no_sourcemap.js:3:9)
5+
at file:///[WILDCARD]no_sourcemap.js:6:1
Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
1-
[WILDCARD]error: Uncaught[WILDCARD] Error: Error from file outside cwd
2-
[WILDCARD]at throwError ([WILDCARD]/absolute/path/outside/original.ts:3:[WILDCARD]
3-
[WILDCARD]at [WILDCARD]/absolute/path/outside/original.ts:6:[WILDCARD]
1+
error: Uncaught (in promise) Error: Error from file outside cwd
2+
at throwError (file:///[WILDCARD]original.ts:3:1)
3+
at file:///[WILDCARD]original.ts:6:1
Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
1-
[WILDCARD]error: Uncaught[WILDCARD] Error: Test error with trailing content
2-
[WILDCARD]at throwError ([WILDCARD]test.ts:4:[WILDCARD]
3-
[WILDCARD]at [WILDCARD]test.ts:6:[WILDCARD]
1+
error: Uncaught (in promise) Error: Test error with trailing content
2+
at throwError (file:///[WILDCARD]test.ts:4:1)
3+
at file:///[WILDCARD]test.ts:6:1

0 commit comments

Comments
 (0)