summaryrefslogtreecommitdiff
path: root/tests/specs/fmt/no_error_deno_dir_not_exists
diff options
context:
space:
mode:
authorDavid Sherret <dsherret@users.noreply.github.com>2024-04-01 18:58:52 -0400
committerGitHub <noreply@github.com>2024-04-01 18:58:52 -0400
commitb0c1bd82a85ddb54ffe717a2c158c33c0be99fe8 (patch)
tree111cefee08d16935f2bab467db0328e670c14243 /tests/specs/fmt/no_error_deno_dir_not_exists
parent240b362c002d17bc2b676673ed1b9406683ff0c2 (diff)
fix: prevent cache db errors when deno_dir not exists (#23168)
Closes #20202
Diffstat (limited to 'tests/specs/fmt/no_error_deno_dir_not_exists')
-rw-r--r--tests/specs/fmt/no_error_deno_dir_not_exists/__test__.jsonc8
-rw-r--r--tests/specs/fmt/no_error_deno_dir_not_exists/fmt.out2
-rw-r--r--tests/specs/fmt/no_error_deno_dir_not_exists/main.ts1
3 files changed, 11 insertions, 0 deletions
diff --git a/tests/specs/fmt/no_error_deno_dir_not_exists/__test__.jsonc b/tests/specs/fmt/no_error_deno_dir_not_exists/__test__.jsonc
new file mode 100644
index 000000000..4e4f67477
--- /dev/null
+++ b/tests/specs/fmt/no_error_deno_dir_not_exists/__test__.jsonc
@@ -0,0 +1,8 @@
+{
+ "tempDir": true,
+ "envs": {
+ "DENO_DIR": "$DENO_DIR/not_exists"
+ },
+ "args": "fmt --log-level=debug main.ts",
+ "output": "fmt.out"
+}
diff --git a/tests/specs/fmt/no_error_deno_dir_not_exists/fmt.out b/tests/specs/fmt/no_error_deno_dir_not_exists/fmt.out
new file mode 100644
index 000000000..930bcb5c6
--- /dev/null
+++ b/tests/specs/fmt/no_error_deno_dir_not_exists/fmt.out
@@ -0,0 +1,2 @@
+[WILDCARD]Created parent directory for cache db.[WILDCARD]
+Checked 1 file
diff --git a/tests/specs/fmt/no_error_deno_dir_not_exists/main.ts b/tests/specs/fmt/no_error_deno_dir_not_exists/main.ts
new file mode 100644
index 000000000..296d5492b
--- /dev/null
+++ b/tests/specs/fmt/no_error_deno_dir_not_exists/main.ts
@@ -0,0 +1 @@
+console.log(1);