diff options
| author | Bartek IwaĆczuk <biwanczuk@gmail.com> | 2024-08-14 21:50:06 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-08-14 22:50:06 +0200 |
| commit | 22a834ff5b4b312b8f91be8991f2b495d49fad2f (patch) | |
| tree | 66ed83a0898396a950c040aa70192bda95f9102e /tests/integration/js_unit_tests.rs | |
| parent | f89b5311492377a3ac18d756dc8c8a309e2c9e8a (diff) | |
test: run unit tests with DENO_FUTURE=1 (#24400)
This commit adds another test suite that runs all Deno unit tests
with `DENO_FUTURE=1` flag to ensure all APIs are working as
expected, once Deno 2 is released.
---------
Co-authored-by: Divy Srivastava <dj.srivastava23@gmail.com>
Diffstat (limited to 'tests/integration/js_unit_tests.rs')
| -rw-r--r-- | tests/integration/js_unit_tests.rs | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/tests/integration/js_unit_tests.rs b/tests/integration/js_unit_tests.rs index cbae4a0b8..bc6c5bdae 100644 --- a/tests/integration/js_unit_tests.rs +++ b/tests/integration/js_unit_tests.rs @@ -117,6 +117,10 @@ util::unit_test_factory!( ); fn js_unit_test(test: String) { + js_unit_test_inner(test, false); +} + +pub fn js_unit_test_inner(test: String, future: bool) { let _g = util::http_server(); let deno = util::deno_cmd() @@ -129,6 +133,12 @@ fn js_unit_test(test: String) { .arg("--location=http://127.0.0.1:4545/") .arg("--no-prompt"); + let deno = if future { + deno.env("DENO_FUTURE", "1") + } else { + deno + }; + // TODO(mmastrac): it would be better to just load a test CA for all tests let deno = if test == "websocket_test" || test == "tls_sni_test" { deno.arg("--unsafely-ignore-certificate-errors") |
