diff options
author | Casper Beyer <caspervonb@pm.me> | 2021-06-29 21:40:16 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-06-29 15:40:16 +0200 |
commit | a0c0daac24c496e49e7c0abaae12f34723785a7d (patch) | |
tree | adc16fea74b191f2ddcfe86eaa425c4e1a5e2f3d /cli/tests/test/finally_timeout.ts | |
parent | 96d05829002ef065b8fc84fe70de062cff0e95b3 (diff) |
test(cli): harden test runner tests (#11166)
Diffstat (limited to 'cli/tests/test/finally_timeout.ts')
-rw-r--r-- | cli/tests/test/finally_timeout.ts | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/cli/tests/test/finally_timeout.ts b/cli/tests/test/finally_timeout.ts new file mode 100644 index 000000000..dcc0a4d64 --- /dev/null +++ b/cli/tests/test/finally_timeout.ts @@ -0,0 +1,11 @@ +Deno.test("error", function () { + const timer = setTimeout(() => null, 10000); + try { + throw new Error("fail"); + } finally { + clearTimeout(timer); + } +}); + +Deno.test("success", function () { +}); |