mirror of
https://github.com/denoland/deno.git
synced 2025-01-09 15:48:16 -05:00
fix(cli/install): preserve compat flag (#14223)
This commit is contained in:
parent
0df1854249
commit
b8d66a683a
1 changed files with 6 additions and 0 deletions
|
@ -334,6 +334,10 @@ fn resolve_shim_data(
|
||||||
executable_args.push("--no-prompt".to_string());
|
executable_args.push("--no-prompt".to_string());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if flags.compat {
|
||||||
|
executable_args.push("--compat".to_string());
|
||||||
|
}
|
||||||
|
|
||||||
if !flags.v8_flags.is_empty() {
|
if !flags.v8_flags.is_empty() {
|
||||||
executable_args.push(format!("--v8-flags={}", flags.v8_flags.join(",")));
|
executable_args.push(format!("--v8-flags={}", flags.v8_flags.join(",")));
|
||||||
}
|
}
|
||||||
|
@ -588,6 +592,7 @@ mod tests {
|
||||||
allow_read: Some(vec![]),
|
allow_read: Some(vec![]),
|
||||||
typecheck_mode: TypecheckMode::None,
|
typecheck_mode: TypecheckMode::None,
|
||||||
log_level: Some(Level::Error),
|
log_level: Some(Level::Error),
|
||||||
|
compat: true,
|
||||||
..Flags::default()
|
..Flags::default()
|
||||||
},
|
},
|
||||||
&InstallFlags {
|
&InstallFlags {
|
||||||
|
@ -609,6 +614,7 @@ mod tests {
|
||||||
"--allow-net",
|
"--allow-net",
|
||||||
"--quiet",
|
"--quiet",
|
||||||
"--no-check",
|
"--no-check",
|
||||||
|
"--compat",
|
||||||
"http://localhost:4545/echo_server.ts",
|
"http://localhost:4545/echo_server.ts",
|
||||||
"--foobar",
|
"--foobar",
|
||||||
]
|
]
|
||||||
|
|
Loading…
Reference in a new issue