From 89424f8e4a339d42f17e772f5f65fc89e024a8ca Mon Sep 17 00:00:00 2001 From: Divy Srivastava Date: Fri, 24 Nov 2023 19:46:16 -0800 Subject: perf: move "cli/js/40_testing.js" out of main snapshot (#21212) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Closes https://github.com/denoland/deno/issues/21136 --------- Co-authored-by: Bartek IwaƄczuk --- runtime/js/99_main.js | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'runtime') diff --git a/runtime/js/99_main.js b/runtime/js/99_main.js index 89296d632..1af2585a5 100644 --- a/runtime/js/99_main.js +++ b/runtime/js/99_main.js @@ -448,6 +448,11 @@ const finalDenoNs = { resources: core.resources, close: core.close, ...denoNs, + // Deno.test and Deno.bench are noops here, but kept for compatibility; so + // that they don't cause errors when used outside of `deno test`/`deno bench` + // contexts. + test: () => {}, + bench: () => {}, }; const { -- cgit v1.2.3