Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(225)

Unified Diff: LayoutTests/push_messaging/push-messaging-resolve-after-detached.html

Issue 396963002: ServiceWorker: Bypass resolving a promise when ExecutionContext is gone (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: rebase Created 6 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: LayoutTests/push_messaging/push-messaging-resolve-after-detached.html
diff --git a/LayoutTests/push_messaging/push-messaging-resolve-after-detached.html b/LayoutTests/push_messaging/push-messaging-resolve-after-detached.html
new file mode 100644
index 0000000000000000000000000000000000000000..a41e22d0934bc092ddfedcf62f2cf8f2b05d411f
--- /dev/null
+++ b/LayoutTests/push_messaging/push-messaging-resolve-after-detached.html
@@ -0,0 +1,28 @@
+<!DOCTYPE html>
+<html>
+<head>
+<script src="../resources/js-test.js"></script>
+</head>
+<body>
+<script>
+description("Test that resolving a promise after the window gets closed does not assert or crash.");
+
+var jsTestIsAsync = true;
+
+function openWindow() {
+ window.open('resources/push-messaging-resolve-after-detached.html');
+}
+
+function done() {
+ finishJSTest();
+}
+
+if (window.testRunner) {
+ testRunner.dumpAsText();
+ testRunner.setCanOpenWindows();
+ openWindow();
+}
+</script>
+</body>
+</html>
+

Powered by Google App Engine
This is Rietveld 408576698