summaryrefslogtreecommitdiff
path: root/cli/tests/testdata
diff options
context:
space:
mode:
Diffstat (limited to 'cli/tests/testdata')
-rw-r--r--cli/tests/testdata/check/deno_not_found/main.out4
-rw-r--r--cli/tests/testdata/check/deno_not_found/main.ts4
-rw-r--r--cli/tests/testdata/check/deno_unstable_not_found/main.out16
-rw-r--r--cli/tests/testdata/check/deno_unstable_not_found/main.ts2
-rw-r--r--cli/tests/testdata/run/unstable_disabled.out2
5 files changed, 27 insertions, 1 deletions
diff --git a/cli/tests/testdata/check/deno_not_found/main.out b/cli/tests/testdata/check/deno_not_found/main.out
new file mode 100644
index 000000000..39852ab95
--- /dev/null
+++ b/cli/tests/testdata/check/deno_not_found/main.out
@@ -0,0 +1,4 @@
+error: TS2304 [ERROR]: Cannot find name 'Deno'. Do you need to change your target library? Try changing the 'lib' compiler option to include 'deno.ns' or add a triple-slash directive to your entrypoint: /// <reference lib="deno.ns" />
+Deno;
+~~~~
+ at file:///[WILDCARD]/check/deno_not_found/main.ts:4:1
diff --git a/cli/tests/testdata/check/deno_not_found/main.ts b/cli/tests/testdata/check/deno_not_found/main.ts
new file mode 100644
index 000000000..3269f047a
--- /dev/null
+++ b/cli/tests/testdata/check/deno_not_found/main.ts
@@ -0,0 +1,4 @@
+/// <reference no-default-lib="true"/>
+/// <reference lib="es5" />
+
+Deno;
diff --git a/cli/tests/testdata/check/deno_unstable_not_found/main.out b/cli/tests/testdata/check/deno_unstable_not_found/main.out
new file mode 100644
index 000000000..dfe3cf317
--- /dev/null
+++ b/cli/tests/testdata/check/deno_unstable_not_found/main.out
@@ -0,0 +1,16 @@
+error: TS2551 [ERROR]: Property 'openKv' does not exist on type 'typeof Deno'. Did you mean 'open'? 'Deno.openKv' is an unstable API. Did you forget to run with the '--unstable' flag, or did you mean 'open'? If not, try changing the 'lib' compiler option to include 'deno.unstable' or add a triple-slash directive to your entrypoint: /// <reference lib="deno.unstable" />
+Deno.openKv;
+ ~~~~~~
+ at file:///[WILDCARD]/deno_unstable_not_found/main.ts:1:6
+
+ 'open' is declared here.
+ export function open(
+ ~~~~
+ at asset:///lib.deno.ns.d.ts:1667:19
+
+TS2339 [ERROR]: Property 'createHttpClient' does not exist on type 'typeof Deno'. 'Deno.createHttpClient' is an unstable API. Did you forget to run with the '--unstable' flag? If not, try changing the 'lib' compiler option to include 'deno.unstable' or add a triple-slash directive to your entrypoint: /// <reference lib="deno.unstable" />
+Deno.createHttpClient;
+ ~~~~~~~~~~~~~~~~
+ at file:///[WILDCARD]/deno_unstable_not_found/main.ts:2:6
+
+Found 2 errors.
diff --git a/cli/tests/testdata/check/deno_unstable_not_found/main.ts b/cli/tests/testdata/check/deno_unstable_not_found/main.ts
new file mode 100644
index 000000000..6661bd205
--- /dev/null
+++ b/cli/tests/testdata/check/deno_unstable_not_found/main.ts
@@ -0,0 +1,2 @@
+Deno.openKv;
+Deno.createHttpClient;
diff --git a/cli/tests/testdata/run/unstable_disabled.out b/cli/tests/testdata/run/unstable_disabled.out
index f3de913e6..fb8d3ee05 100644
--- a/cli/tests/testdata/run/unstable_disabled.out
+++ b/cli/tests/testdata/run/unstable_disabled.out
@@ -1,5 +1,5 @@
[WILDCARD]
-error: TS2339 [ERROR]: Property 'umask' does not exist on type 'typeof Deno'. 'Deno.umask' is an unstable API. Did you forget to run with the '--unstable' flag?
+error: TS2339 [ERROR]: Property 'umask' does not exist on type 'typeof Deno'. 'Deno.umask' is an unstable API. Did you forget to run with the '--unstable' flag? If not, try changing the 'lib' compiler option to include 'deno.unstable' or add a triple-slash directive to your entrypoint: /// <reference lib="deno.unstable" />
console.log(Deno.umask);
~~~~~
at [WILDCARD]/unstable.ts:1:18