summaryrefslogtreecommitdiff
path: root/tests/testdata
diff options
context:
space:
mode:
authorDavid Sherret <dsherret@users.noreply.github.com>2024-05-14 19:51:51 -0400
committerGitHub <noreply@github.com>2024-05-14 23:51:51 +0000
commit1a788b58a0e80c4504a0fdf5d47db41c46dc8d37 (patch)
tree4b780c3a09d92c18a381a25d7213828721c05b1f /tests/testdata
parente389917535e8e7ef13920a96f9c9c1e1ec2b2c55 (diff)
chore: fix flaky rejection_handled_web_process (#23817)
Closes https://github.com/denoland/deno/issues/23712
Diffstat (limited to 'tests/testdata')
-rw-r--r--tests/testdata/node/rejection_handled_web_process.ts26
-rw-r--r--tests/testdata/node/rejection_handled_web_process.ts.out6
2 files changed, 0 insertions, 32 deletions
diff --git a/tests/testdata/node/rejection_handled_web_process.ts b/tests/testdata/node/rejection_handled_web_process.ts
deleted file mode 100644
index a5136ca3d..000000000
--- a/tests/testdata/node/rejection_handled_web_process.ts
+++ /dev/null
@@ -1,26 +0,0 @@
-import chalk from "npm:chalk";
-import process from "node:process";
-
-console.log(chalk.red("Hello world!"));
-
-globalThis.addEventListener("unhandledrejection", (e) => {
- console.log('globalThis.addEventListener("unhandledrejection");');
- e.preventDefault();
-});
-
-globalThis.addEventListener("rejectionhandled", (_) => {
- console.log("Web rejectionhandled");
-});
-
-process.on("rejectionHandled", (_) => {
- console.log("Node rejectionHandled");
-});
-
-const a = Promise.reject(1);
-setTimeout(() => {
- a.catch(() => console.log("Added catch handler to the promise"));
-}, 100);
-
-setTimeout(() => {
- console.log("Success");
-}, 1000);
diff --git a/tests/testdata/node/rejection_handled_web_process.ts.out b/tests/testdata/node/rejection_handled_web_process.ts.out
deleted file mode 100644
index e6fefede2..000000000
--- a/tests/testdata/node/rejection_handled_web_process.ts.out
+++ /dev/null
@@ -1,6 +0,0 @@
-Hello world!
-globalThis.addEventListener("unhandledrejection");
-Added catch handler to the promise
-Web rejectionhandled
-Node rejectionHandled
-Success