diff options
Diffstat (limited to 'cli/tests/integration/compile_tests.rs')
| -rw-r--r-- | cli/tests/integration/compile_tests.rs | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/cli/tests/integration/compile_tests.rs b/cli/tests/integration/compile_tests.rs index df339c369..653b2bc8d 100644 --- a/cli/tests/integration/compile_tests.rs +++ b/cli/tests/integration/compile_tests.rs @@ -1061,3 +1061,27 @@ fn compile_node_modules_symlink_outside() { let output = context.new_command().name(binary_path).run(); output.assert_matches_file("compile/node_modules_symlink_outside/main.out"); } + +#[test] +fn dynamic_imports_tmp_lit() { + let context = TestContextBuilder::new().build(); + let dir = context.temp_dir(); + let exe = if cfg!(windows) { + dir.path().join("app.exe") + } else { + dir.path().join("app") + }; + let output = context + .new_command() + .args_vec([ + "compile", + "--output", + &exe.to_string_lossy(), + "./compile/dynamic_imports_tmp_lit/main.js", + ]) + .run(); + output.assert_exit_code(0); + output.skip_output_check(); + let output = context.new_command().name(&exe).run(); + output.assert_matches_text("a\nb\n{ data: 5 }\n{ data: 1 }\n"); +} |
