feat(cli/test): add DENO_JOBS env variable for test subcommand (#14929)

This commit is contained in:
Mark Ladyshau 2022-07-15 16:29:55 +02:00 committed by GitHub
parent f9b692e68e
commit ee0c0586b3
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 48 additions and 1 deletions

View file

@ -62,6 +62,32 @@ itest!(collect {
output: "test/collect.out",
});
itest!(jobs_flag {
args: "test test/short-pass.ts --jobs",
exit_code: 0,
output: "test/short-pass.out",
});
itest!(jobs_flag_with_numeric_value {
args: "test test/short-pass.ts --jobs=2",
exit_code: 0,
output: "test/short-pass-jobs-flag-with-numeric-value.out",
});
itest!(jobs_flag_with_env_variable {
args: "test test/short-pass.ts --jobs",
envs: vec![("DENO_JOBS".to_owned(), "2".to_owned())],
exit_code: 0,
output: "test/short-pass.out",
});
itest!(jobs_flag_with_numeric_value_and_env_var {
args: "test test/short-pass.ts --jobs=2",
envs: vec![("DENO_JOBS".to_owned(), "3".to_owned())],
exit_code: 0,
output: "test/short-pass-jobs-flag-with-numeric-value.out",
});
itest!(load_unload {
args: "test test/load_unload.ts",
exit_code: 0,