From 91da410fc3bfde76c3c8930c6f8bfd4d5f9b974e Mon Sep 17 00:00:00 2001 From: Nayeem Rahman Date: Tue, 3 Dec 2019 22:48:53 +0000 Subject: feat: Add --no-remote, rename --no-fetch to --cached-only (#3417) --- cli/tests/035_cached_only_flag.out | 1 + cli/tests/035_no_fetch_flag.out | 1 - cli/tests/052_no_remote_flag.out | 1 + cli/tests/integration_tests.rs | 15 ++++++++++++--- 4 files changed, 14 insertions(+), 4 deletions(-) create mode 100644 cli/tests/035_cached_only_flag.out delete mode 100644 cli/tests/035_no_fetch_flag.out create mode 100644 cli/tests/052_no_remote_flag.out (limited to 'cli/tests') diff --git a/cli/tests/035_cached_only_flag.out b/cli/tests/035_cached_only_flag.out new file mode 100644 index 000000000..1c63a86b0 --- /dev/null +++ b/cli/tests/035_cached_only_flag.out @@ -0,0 +1 @@ +Cannot find module "http://127.0.0.1:4545/cli/tests/019_media_types.ts" in cache, --cached-only is specified diff --git a/cli/tests/035_no_fetch_flag.out b/cli/tests/035_no_fetch_flag.out deleted file mode 100644 index 26f020aa5..000000000 --- a/cli/tests/035_no_fetch_flag.out +++ /dev/null @@ -1 +0,0 @@ -Cannot resolve module "http://127.0.0.1:4545/cli/tests/019_media_types.ts" diff --git a/cli/tests/052_no_remote_flag.out b/cli/tests/052_no_remote_flag.out new file mode 100644 index 000000000..26f020aa5 --- /dev/null +++ b/cli/tests/052_no_remote_flag.out @@ -0,0 +1 @@ +Cannot resolve module "http://127.0.0.1:4545/cli/tests/019_media_types.ts" diff --git a/cli/tests/integration_tests.rs b/cli/tests/integration_tests.rs index 3cc8039db..4eef5dbc6 100644 --- a/cli/tests/integration_tests.rs +++ b/cli/tests/integration_tests.rs @@ -296,10 +296,10 @@ itest!(_034_onload { output: "034_onload.out", }); -itest!(_035_no_fetch_flag { +itest!(_035_cached_only_flag { args: - "--reload --no-fetch http://127.0.0.1:4545/cli/tests/019_media_types.ts", - output: "035_no_fetch_flag.out", + "--reload --cached-only http://127.0.0.1:4545/cli/tests/019_media_types.ts", + output: "035_cached_only_flag.out", exit_code: 1, check_stderr: true, http_server: true, @@ -397,6 +397,15 @@ itest!(_051_wasm_import { http_server: true, }); +itest!(_052_no_remote_flag { + args: + "--reload --no-remote http://127.0.0.1:4545/cli/tests/019_media_types.ts", + output: "052_no_remote_flag.out", + exit_code: 1, + check_stderr: true, + http_server: true, +}); + itest!(lock_check_ok { args: "run --lock=lock_check_ok.json http://127.0.0.1:4545/cli/tests/003_relative_import.ts", output: "003_relative_import.ts.out", -- cgit v1.2.3