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

Unified Diff: third_party/WebKit/LayoutTests/fast/dom/Geolocation/window-close-crash.html

Issue 2667393002: Stop using script-tests in fast/dom/. (Closed)
Patch Set: . Created 3 years, 11 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: third_party/WebKit/LayoutTests/fast/dom/Geolocation/window-close-crash.html
diff --git a/third_party/WebKit/LayoutTests/fast/dom/Geolocation/window-close-crash.html b/third_party/WebKit/LayoutTests/fast/dom/Geolocation/window-close-crash.html
index 6436e34ef51c61320a57f595c1849c7b9ceba71b..68f1e5433f5726d18ec1b004f679e913d4aa8148 100644
--- a/third_party/WebKit/LayoutTests/fast/dom/Geolocation/window-close-crash.html
+++ b/third_party/WebKit/LayoutTests/fast/dom/Geolocation/window-close-crash.html
@@ -6,6 +6,41 @@
<script src="resources/geolocation-mock.js"></script>
</head>
<body>
-<script src="script-tests/window-close-crash.js"></script>
+<script>
+description("Tests the assertion that the GeolocationClient should not be updating<br>" +
+ "when the GeolocationController is destroyed.<br>" +
+ "See https://bugs.webkit.org/show_bug.cgi?id=52216");
+
+if (!window.testRunner)
+ debug('This test can not run without testRunner');
+
+testRunner.waitUntilDone();
+testRunner.setCanOpenWindows();
+testRunner.setCloseRemainingWindowsWhenComplete(true);
+
+var otherWindow;
+
+function gotPosition(p)
+{
+ testPassed("Received Geoposition.");
+ otherWindow.close();
+ window.setTimeout(waitForWindowToClose, 0);
+}
+
+function waitForWindowToClose()
+{
+ if (!otherWindow.closed) {
+ window.setTimeout(waitForWindowToClose, 0);
+ return;
+ }
+ testPassed("Success - no crash!");
+ finishJSTest();
+}
+
+debug("Main page opening resources/window-close-popup.html");
+otherWindow = window.open("resources/window-close-popup.html");
+
+window.jsTestIsAsync = true;
+</script>
</body>
</html>

Powered by Google App Engine
This is Rietveld 408576698