diff options
author | David Sherret <dsherret@users.noreply.github.com> | 2023-11-01 15:59:51 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-11-01 19:59:51 +0000 |
commit | 02822d309f6a3ca1a092670905605dd72f15b384 (patch) | |
tree | bee2e50ac74f5c0e99cd73bba63f076048cd833e /cli/tests/integration/test_tests.rs | |
parent | d42f1543121e7245789a96a485d1ef7645cb5fba (diff) |
fix(test): --junit-path should handle when the dir doesn't exist (#21044)
Closes https://github.com/denoland/deno/issues/21022
Diffstat (limited to 'cli/tests/integration/test_tests.rs')
-rw-r--r-- | cli/tests/integration/test_tests.rs | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/cli/tests/integration/test_tests.rs b/cli/tests/integration/test_tests.rs index bcf3e4ef7..4560f95b6 100644 --- a/cli/tests/integration/test_tests.rs +++ b/cli/tests/integration/test_tests.rs @@ -283,6 +283,23 @@ itest!(junit { output: "test/pass.junit.out", }); +#[test] +fn junit_path() { + let context = TestContextBuilder::new().use_temp_cwd().build(); + let temp_dir = context.temp_dir(); + temp_dir.write("test.js", "Deno.test('does test', () => {});"); + let output = context + .new_command() + .args("test --junit-path=sub_dir/output.xml test.js") + .run(); + output.skip_output_check(); + output.assert_exit_code(0); + temp_dir + .path() + .join("sub_dir/output.xml") + .assert_matches_text("<?xml [WILDCARD]"); +} + itest!(clear_timeout { args: "test test/clear_timeout.ts", exit_code: 0, |