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

Unified Diff: LayoutTests/fast/dom/Window/window-closed-immediate.html

Issue 1053073002: Improve window.closed fidelity. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: rebased Created 5 years, 8 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/fast/dom/Window/window-closed-immediate.html
diff --git a/LayoutTests/vibration/vibration-detached-no-crash.html b/LayoutTests/fast/dom/Window/window-closed-immediate.html
similarity index 60%
copy from LayoutTests/vibration/vibration-detached-no-crash.html
copy to LayoutTests/fast/dom/Window/window-closed-immediate.html
index 7e0de30d42831b7ab5aec3aa758a641a9c50fc8c..346ce363a2de91e06441ec31e61784e0e0044a89 100644
--- a/LayoutTests/vibration/vibration-detached-no-crash.html
+++ b/LayoutTests/fast/dom/Window/window-closed-immediate.html
@@ -1,29 +1,29 @@
<!DOCTYPE HTML>
<body>
<head>
-<script src="../resources/js-test.js"></script>
-<script src="vibration-utils.js"></script>
+<script src="../../../resources/js-test.js"></script>
</head>
<script>
-description("Accessing navigator.vibrate on a closed window.");
+description("window.closed should return true after window.close().");
window.jsTestIsAsync = true;
+if (window.testRunner) {
+ testRunner.dumpAsText();
+ testRunner.setCanOpenWindows();
+}
var w;
function processMessage(event) {
if (event.data == "opened") {
w.close();
+ shouldBeTrue("w.closed");
} else if (event.data == "closed") {
- shouldBeFalse("w.navigator.vibrate([])");
+ shouldBeTrue("w.closed");
finishJSTest();
}
}
-if (window.testRunner) {
- testRunner.dumpAsText();
- testRunner.setCanOpenWindows();
-}
-w = window.open('../resources/window-postmessage-open-close.html');
+w = window.open('../../../resources/window-postmessage-open-close.html');
window.addEventListener("message", processMessage, false);
</script>
</body>
« no previous file with comments | « no previous file | LayoutTests/fast/dom/Window/window-closed-immediate-expected.txt » ('j') | Source/core/frame/DOMWindow.cpp » ('J')

Powered by Google App Engine
This is Rietveld 408576698