summaryrefslogtreecommitdiff
path: root/tests/testdata/run/webstorage
diff options
context:
space:
mode:
Diffstat (limited to 'tests/testdata/run/webstorage')
-rw-r--r--tests/testdata/run/webstorage/config_a.jsonc3
-rw-r--r--tests/testdata/run/webstorage/config_b.jsonc3
-rw-r--r--tests/testdata/run/webstorage/fixture.ts2
-rw-r--r--tests/testdata/run/webstorage/logger.ts1
-rw-r--r--tests/testdata/run/webstorage/serialization.ts4
-rw-r--r--tests/testdata/run/webstorage/serialization.ts.out2
-rw-r--r--tests/testdata/run/webstorage/setter.ts1
7 files changed, 16 insertions, 0 deletions
diff --git a/tests/testdata/run/webstorage/config_a.jsonc b/tests/testdata/run/webstorage/config_a.jsonc
new file mode 100644
index 000000000..875cb6001
--- /dev/null
+++ b/tests/testdata/run/webstorage/config_a.jsonc
@@ -0,0 +1,3 @@
+{
+ "compilerOptions": {}
+}
diff --git a/tests/testdata/run/webstorage/config_b.jsonc b/tests/testdata/run/webstorage/config_b.jsonc
new file mode 100644
index 000000000..875cb6001
--- /dev/null
+++ b/tests/testdata/run/webstorage/config_b.jsonc
@@ -0,0 +1,3 @@
+{
+ "compilerOptions": {}
+}
diff --git a/tests/testdata/run/webstorage/fixture.ts b/tests/testdata/run/webstorage/fixture.ts
new file mode 100644
index 000000000..cf4bd9f1f
--- /dev/null
+++ b/tests/testdata/run/webstorage/fixture.ts
@@ -0,0 +1,2 @@
+import "./logger.ts";
+import "./setter.ts";
diff --git a/tests/testdata/run/webstorage/logger.ts b/tests/testdata/run/webstorage/logger.ts
new file mode 100644
index 000000000..3898c4445
--- /dev/null
+++ b/tests/testdata/run/webstorage/logger.ts
@@ -0,0 +1 @@
+console.log(window.localStorage);
diff --git a/tests/testdata/run/webstorage/serialization.ts b/tests/testdata/run/webstorage/serialization.ts
new file mode 100644
index 000000000..f3791d355
--- /dev/null
+++ b/tests/testdata/run/webstorage/serialization.ts
@@ -0,0 +1,4 @@
+window.sessionStorage.setItem("hello", "deno");
+
+console.log(window.localStorage);
+console.log(window.sessionStorage);
diff --git a/tests/testdata/run/webstorage/serialization.ts.out b/tests/testdata/run/webstorage/serialization.ts.out
new file mode 100644
index 000000000..4d80032f0
--- /dev/null
+++ b/tests/testdata/run/webstorage/serialization.ts.out
@@ -0,0 +1,2 @@
+Storage {[WILDCARD]
+Storage { hello: "deno", length: 1 }
diff --git a/tests/testdata/run/webstorage/setter.ts b/tests/testdata/run/webstorage/setter.ts
new file mode 100644
index 000000000..ec6d474f5
--- /dev/null
+++ b/tests/testdata/run/webstorage/setter.ts
@@ -0,0 +1 @@
+window.localStorage.setItem("hello", "deno");