From 4b3845b998ae2f7cd6e02625b4cfc3613878ceb2 Mon Sep 17 00:00:00 2001 From: David Sherret Date: Thu, 24 Jun 2021 09:00:46 -0400 Subject: feat(repl): support import declarations in the REPL (#11086) --- cli/tests/integration_tests.rs | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'cli/tests') diff --git a/cli/tests/integration_tests.rs b/cli/tests/integration_tests.rs index da436b5bd..393d41da4 100644 --- a/cli/tests/integration_tests.rs +++ b/cli/tests/integration_tests.rs @@ -2369,6 +2369,18 @@ mod integration { assert!(out.contains("hello!\n")); } + #[test] + fn import_declarations() { + let (out, _) = util::run_and_collect_output( + true, + "repl", + Some(vec!["import './subdir/auto_print_hello.ts';"]), + Some(vec![("NO_COLOR".to_owned(), "1".to_owned())]), + false, + ); + assert!(out.contains("hello!\n")); + } + #[test] fn eval_unterminated() { let (out, err) = util::run_and_collect_output( -- cgit v1.2.3