diff options
Diffstat (limited to 'cli/tests/078_unload_on_exit.ts')
-rw-r--r-- | cli/tests/078_unload_on_exit.ts | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/cli/tests/078_unload_on_exit.ts b/cli/tests/078_unload_on_exit.ts index e8288ef31..43d33eb25 100644 --- a/cli/tests/078_unload_on_exit.ts +++ b/cli/tests/078_unload_on_exit.ts @@ -1,4 +1,9 @@ window.onunload = () => { console.log("onunload is called"); + // This second exit call doesn't trigger unload event, + // and therefore actually stops the process. + Deno.exit(1); + console.log("This doesn't show up in console"); }; +// This exit call triggers the above unload event handler. Deno.exit(0); |