diff options
author | David Sherret <dsherret@users.noreply.github.com> | 2023-02-27 16:52:49 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-02-27 16:52:49 -0400 |
commit | 7c090b1b14e6b5000dbbed434525387c414ca62c (patch) | |
tree | 1645fbd8a8b1aee55f79cfe74d2bb7ecadcf5215 /cli/tests/integration/test_tests.rs | |
parent | 6bbb4c3af60d568a34e1472a0721ddd8a3dab469 (diff) |
chore: test builders for integration tests (#17965)
Start of adding test builders to simplify integration tests.
I only updated a few test files. We can complete upgrading over time.
Diffstat (limited to 'cli/tests/integration/test_tests.rs')
-rw-r--r-- | cli/tests/integration/test_tests.rs | 12 |
1 files changed, 5 insertions, 7 deletions
diff --git a/cli/tests/integration/test_tests.rs b/cli/tests/integration/test_tests.rs index d52109d2b..0ff09e69d 100644 --- a/cli/tests/integration/test_tests.rs +++ b/cli/tests/integration/test_tests.rs @@ -2,7 +2,9 @@ use deno_core::url::Url; use test_util as util; +use util::assert_output_file; use util::env_vars_for_npm_tests; +use util::TestContext; #[test] fn no_color() { @@ -414,13 +416,9 @@ fn file_protocol() { .unwrap() .to_string(); - (util::CheckOutputIntegrationTest { - args_vec: vec!["test", &file_url], - exit_code: 0, - output: "test/file_protocol.out", - ..Default::default() - }) - .run(); + let context = TestContext::default(); + let output = context.new_command().args(format!("test {file_url}")).run(); + assert_output_file!(output, "test/file_protocol.out"); } itest!(uncaught_errors { |