diff options
Diffstat (limited to 'cli/tests/compile_tests.rs')
-rw-r--r-- | cli/tests/compile_tests.rs | 34 |
1 files changed, 34 insertions, 0 deletions
diff --git a/cli/tests/compile_tests.rs b/cli/tests/compile_tests.rs index 869a8780e..970ef5ee3 100644 --- a/cli/tests/compile_tests.rs +++ b/cli/tests/compile_tests.rs @@ -449,6 +449,40 @@ mod compile { } #[test] + fn standalone_import_map_config_file() { + let dir = TempDir::new(); + let exe = if cfg!(windows) { + dir.path().join("import_map.exe") + } else { + dir.path().join("import_map") + }; + let output = util::deno_cmd() + .current_dir(util::testdata_path()) + .arg("compile") + .arg("--unstable") + .arg("--allow-read") + .arg("--config") + .arg("compile/standalone_import_map_config.json") + .arg("--output") + .arg(&exe) + .arg("./compile/standalone_import_map.ts") + .stdout(std::process::Stdio::piped()) + .spawn() + .unwrap() + .wait_with_output() + .unwrap(); + assert!(output.status.success()); + let output = Command::new(exe) + .stdout(std::process::Stdio::piped()) + .stderr(std::process::Stdio::piped()) + .spawn() + .unwrap() + .wait_with_output() + .unwrap(); + assert!(output.status.success()); + } + + #[test] // https://github.com/denoland/deno/issues/12670 fn skip_rebundle() { let dir = TempDir::new(); |