summaryrefslogtreecommitdiff
path: root/cli/tests/integration/lsp_tests.rs
diff options
context:
space:
mode:
authorNayeem Rahman <nayeemrmn99@gmail.com>2023-07-01 23:52:30 +0100
committerGitHub <noreply@github.com>2023-07-02 00:52:30 +0200
commitb9c0e7cd550ab14fa7da7e33ed87cbeeeb9785a0 (patch)
tree9212eb183ab3c21ee71531e54f2c16163d1792b7 /cli/tests/integration/lsp_tests.rs
parent4e2f02639ef2cbcfdd335c4446f6faa6a29ad264 (diff)
Reland "fix(cli): don't store blob and data urls in the module cache" (#18581)
Relands #18261 now that https://github.com/lucacasonato/esbuild_deno_loader/pull/54 is landed and used by fresh. Fixes #18260.
Diffstat (limited to 'cli/tests/integration/lsp_tests.rs')
-rw-r--r--cli/tests/integration/lsp_tests.rs24
1 files changed, 4 insertions, 20 deletions
diff --git a/cli/tests/integration/lsp_tests.rs b/cli/tests/integration/lsp_tests.rs
index 04b17ef00..52f1e55ba 100644
--- a/cli/tests/integration/lsp_tests.rs
+++ b/cli/tests/integration/lsp_tests.rs
@@ -5612,7 +5612,7 @@ fn lsp_cache_location() {
"text": "import * as a from \"http://127.0.0.1:4545/xTypeScriptTypes.js\";\n// @deno-types=\"http://127.0.0.1:4545/type_definitions/foo.d.ts\"\nimport * as b from \"http://127.0.0.1:4545/type_definitions/foo.js\";\nimport * as c from \"http://127.0.0.1:4545/subdir/type_reference.js\";\nimport * as d from \"http://127.0.0.1:4545/subdir/mod1.ts\";\nimport * as e from \"data:application/typescript;base64,ZXhwb3J0IGNvbnN0IGEgPSAiYSI7CgpleHBvcnQgZW51bSBBIHsKICBBLAogIEIsCiAgQywKfQo=\";\nimport * as f from \"./file_01.ts\";\nimport * as g from \"http://localhost:4545/x/a/mod.ts\";\n\nconsole.log(a, b, c, d, e, f, g);\n"
}
}));
- assert_eq!(diagnostics.all().len(), 7);
+ assert_eq!(diagnostics.all().len(), 6);
client.write_request(
"deno/cache",
json!({
@@ -5708,7 +5708,7 @@ fn lsp_tls_cert() {
}
}));
let diagnostics = diagnostics.all();
- assert_eq!(diagnostics.len(), 7);
+ assert_eq!(diagnostics.len(), 6);
client.write_request(
"deno/cache",
json!({
@@ -7609,25 +7609,9 @@ fn lsp_data_urls_with_jsx_compiler_option() {
}
})).all();
- // there will be a diagnostic about not having cached the data url
- assert_eq!(diagnostics.len(), 1);
- assert_eq!(
- diagnostics[0].code,
- Some(lsp::NumberOrString::String("no-cache-data".to_string()))
- );
+ assert_eq!(diagnostics.len(), 0);
- // so cache it
- client.write_request(
- "deno/cache",
- json!({
- "referrer": {
- "uri": uri,
- },
- "uris": [],
- }),
- );
-
- let res = client.write_request(
+ let res: Value = client.write_request(
"textDocument/references",
json!({
"textDocument": {