diff options
-rw-r--r-- | Cargo.lock | 4 | ||||
-rw-r--r-- | cli/Cargo.toml | 2 | ||||
-rw-r--r-- | tests/specs/compile/relative_permissions/main.ts | 2 | ||||
-rw-r--r-- | tests/testdata/run/resolve_dns.ts | 6 | ||||
-rw-r--r-- | tests/unit/kv_queue_test.ts | 2 | ||||
-rw-r--r-- | tests/unit/net_test.ts | 2 | ||||
-rw-r--r-- | tests/unit/read_file_test.ts | 4 | ||||
-rw-r--r-- | tests/unit/streams_test.ts | 6 | ||||
-rw-r--r-- | tests/unit/tls_test.ts | 4 | ||||
-rw-r--r-- | tests/unit_node/module_test.ts | 2 |
10 files changed, 18 insertions, 16 deletions
diff --git a/Cargo.lock b/Cargo.lock index e45a73980..dd3cc350c 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1374,9 +1374,9 @@ dependencies = [ [[package]] name = "deno_config" -version = "0.33.1" +version = "0.33.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "495df7ebed4feee5c0eb7631b0b86432bb6370638cf81d5eeb5769aab55fb2de" +checksum = "84d90b5eacfd6ee4ec978a11739c71eaeb19a575889f8c2b473430df84078fe2" dependencies = [ "anyhow", "deno_package_json", diff --git a/cli/Cargo.toml b/cli/Cargo.toml index 016488e5c..d9c3e21ad 100644 --- a/cli/Cargo.toml +++ b/cli/Cargo.toml @@ -65,7 +65,7 @@ winres.workspace = true [dependencies] deno_ast = { workspace = true, features = ["bundler", "cjs", "codegen", "proposal", "react", "sourcemap", "transforms", "typescript", "view", "visit"] } deno_cache_dir = { workspace = true } -deno_config = { version = "=0.33.1", features = ["workspace", "sync"] } +deno_config = { version = "=0.33.2", features = ["workspace", "sync"] } deno_core = { workspace = true, features = ["include_js_files_for_snapshotting"] } deno_doc = { version = "0.148.0", features = ["html", "syntect"] } deno_graph = { version = "=0.82.0" } diff --git a/tests/specs/compile/relative_permissions/main.ts b/tests/specs/compile/relative_permissions/main.ts index ac6eebba2..d18d27cad 100644 --- a/tests/specs/compile/relative_permissions/main.ts +++ b/tests/specs/compile/relative_permissions/main.ts @@ -1,5 +1,5 @@ try { Deno.readTextFileSync("a.txt"); } catch (err) { - console.log(err.message); + console.log((err as Error).message); } diff --git a/tests/testdata/run/resolve_dns.ts b/tests/testdata/run/resolve_dns.ts index a2d0fd046..163a68f33 100644 --- a/tests/testdata/run/resolve_dns.ts +++ b/tests/testdata/run/resolve_dns.ts @@ -67,7 +67,7 @@ try { // @ts-ignore testing invalid overloads await Deno.resolveDns("example.com", "SSHFP", nameServer); } catch (e) { - console.log(e.message); + console.log((e as Error).message); } try { @@ -78,7 +78,7 @@ try { signal: ac.signal, }); } catch (e) { - console.log(e.name); + console.log((e as Error).name); } try { @@ -89,5 +89,5 @@ try { signal: ac.signal, }); } catch (e) { - console.log(e.name); + console.log((e as Error).name); } diff --git a/tests/unit/kv_queue_test.ts b/tests/unit/kv_queue_test.ts index e052dcbf7..af5771298 100644 --- a/tests/unit/kv_queue_test.ts +++ b/tests/unit/kv_queue_test.ts @@ -8,6 +8,6 @@ Deno.test({}, async function queueTestDbClose() { await db.listenQueue(() => {}); assertFalse(false); } catch (e) { - assertEquals(e.message, "already closed"); + assertEquals((e as Error).message, "already closed"); } }); diff --git a/tests/unit/net_test.ts b/tests/unit/net_test.ts index 9cd3094e5..1428a804f 100644 --- a/tests/unit/net_test.ts +++ b/tests/unit/net_test.ts @@ -443,7 +443,7 @@ Deno.test( // Note: we have to do the test this way as different OS's have // different UDP size limits enabled, so we will just ensure if // an error is thrown it is the one we are expecting. - assert(err.message.match(rx)); + assert((err as Error).message.match(rx)); alice.close(); bob.close(); return; diff --git a/tests/unit/read_file_test.ts b/tests/unit/read_file_test.ts index 67944813b..6aea6f7af 100644 --- a/tests/unit/read_file_test.ts +++ b/tests/unit/read_file_test.ts @@ -161,7 +161,7 @@ Deno.test( try { await Deno.readFile("definitely-not-found.json"); } catch (e) { - assertEquals(e.code, "ENOENT"); + assertEquals((e as { code: string }).code, "ENOENT"); } }, ); @@ -172,7 +172,7 @@ Deno.test( try { await Deno.readFile("tests/testdata/assets/"); } catch (e) { - assertEquals(e.code, "EISDIR"); + assertEquals((e as { code: string }).code, "EISDIR"); } }, ); diff --git a/tests/unit/streams_test.ts b/tests/unit/streams_test.ts index 80b45e602..b866fa7d5 100644 --- a/tests/unit/streams_test.ts +++ b/tests/unit/streams_test.ts @@ -298,7 +298,7 @@ for ( await core.read(rid, new Uint8Array(1)); fail(); } catch (e) { - assertEquals(e.message, `Uh oh (${type})!`); + assertEquals((e as Error).message, `Uh oh (${type})!`); } core.close(rid); }); @@ -429,7 +429,7 @@ function createStreamTest( fail(); } catch (e) { // We expect this to be thrown - assertEquals(e.message, "Expected error!"); + assertEquals((e as Error).message, "Expected error!"); } } else { const buffer = new Uint8Array(1); @@ -471,7 +471,7 @@ for (const packetCount of [1, 1024]) { } fail(); } catch (e) { - assertEquals(e.message, "operation canceled"); + assertEquals((e as Error).message, "operation canceled"); } assertEquals(await promise, "resource closed"); }); diff --git a/tests/unit/tls_test.ts b/tests/unit/tls_test.ts index 1facd0f98..e5b9a02c3 100644 --- a/tests/unit/tls_test.ts +++ b/tests/unit/tls_test.ts @@ -588,7 +588,9 @@ async function receiveAlotSendNothing(conn: Deno.Conn) { } } catch (e) { throw new Error( - `Got an error (${e.message}) after reading ${nread}/${largeAmount} bytes`, + `Got an error (${ + (e as Error).message + }) after reading ${nread}/${largeAmount} bytes`, { cause: e }, ); } diff --git a/tests/unit_node/module_test.ts b/tests/unit_node/module_test.ts index 994dcfb63..96c3504bd 100644 --- a/tests/unit_node/module_test.ts +++ b/tests/unit_node/module_test.ts @@ -74,7 +74,7 @@ Deno.test("Built-in Node modules have `node:` prefix", () => { createRequire(); } catch (e) { thrown = true; - const stackLines = e.stack.split("\n"); + const stackLines = (e as Error).stack!.split("\n"); // Assert that built-in node modules have `node:<mod_name>` specifiers. assert(stackLines.some((line: string) => line.includes("(node:module:"))); } |