summaryrefslogtreecommitdiffstats
path: root/testing/web-platform/tests/html/browsers/history/the-location-interface/reload_document_open_write-1.html
diff options
context:
space:
mode:
authorMoonchild <moonchild@palemoon.org>2019-12-28 10:14:29 +0000
committerGitHub <noreply@github.com>2019-12-28 10:14:29 +0000
commit357405f6356e28e5fa94cecc078b65c20433d236 (patch)
tree9716965ca2d9d03446fc9290d37e5ef42f80558e /testing/web-platform/tests/html/browsers/history/the-location-interface/reload_document_open_write-1.html
parentf60bbaf9e49733e61aaec675276fcd898ef6bc73 (diff)
parent8b88623463bf30ae7e5fcc64ef7d8d5fb62354c9 (diff)
downloadUXP-357405f6356e28e5fa94cecc078b65c20433d236.tar
UXP-357405f6356e28e5fa94cecc078b65c20433d236.tar.gz
UXP-357405f6356e28e5fa94cecc078b65c20433d236.tar.lz
UXP-357405f6356e28e5fa94cecc078b65c20433d236.tar.xz
UXP-357405f6356e28e5fa94cecc078b65c20433d236.zip
Merge pull request #1335 from MoonchildProductions/document_open
Align document.open() with the overhauled specification
Diffstat (limited to 'testing/web-platform/tests/html/browsers/history/the-location-interface/reload_document_open_write-1.html')
-rw-r--r--testing/web-platform/tests/html/browsers/history/the-location-interface/reload_document_open_write-1.html7
1 files changed, 6 insertions, 1 deletions
diff --git a/testing/web-platform/tests/html/browsers/history/the-location-interface/reload_document_open_write-1.html b/testing/web-platform/tests/html/browsers/history/the-location-interface/reload_document_open_write-1.html
index 1c5a1db8f..e1a2e811c 100644
--- a/testing/web-platform/tests/html/browsers/history/the-location-interface/reload_document_open_write-1.html
+++ b/testing/web-platform/tests/html/browsers/history/the-location-interface/reload_document_open_write-1.html
@@ -3,11 +3,16 @@
<script>
function f() {
opener.postMessage("original", "*");
+ if (opener.data.length >= 2) {
+ // If we proceed here, then our document.write will be racing with the
+ // setTimeout in our opener. Just stop.
+ return;
+ }
setTimeout(function () {
document.open();
document.write("<!doctype html>2<script>opener.postMessage('written', '*');<\/script>");
document.close();
- }), 100;
+ });
}
window.onload = f