Bug 1419297 - Call document.close, triggering onload and making the test not time out. r=smaug
authorBlake Kaplan <mrbkap@gmail.com>
Thu, 07 Jun 2018 16:48:51 -0700
changeset 476194 2762fef0119bcd3e78d36e78b0b75b5448d35c85
parent 476193 a3a7ac1e38f6f6e7bf0f15b6ec5d32e92c1ded87
child 476195 d23cd52cc45bd0b657746386dca8fd77254079fc
push id9374
push userjlund@mozilla.com
push dateMon, 18 Jun 2018 21:43:20 +0000
treeherdermozilla-beta@160e085dfb0b [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerssmaug
bugs1419297
milestone62.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1419297 - Call document.close, triggering onload and making the test not time out. r=smaug This fixes both uses of object-association.js. MozReview-Commit-ID: 8Fj7dC1c3U2
testing/web-platform/meta/MANIFEST.json
testing/web-platform/meta/custom-elements/custom-element-registry/per-global.html.ini
testing/web-platform/meta/html/browsers/history/the-location-interface/per-global.window.js.ini
testing/web-platform/tests/common/object-association.js
--- a/testing/web-platform/meta/MANIFEST.json
+++ b/testing/web-platform/meta/MANIFEST.json
@@ -412954,17 +412954,17 @@
    "e3593850f8098d3f3ff82c042deab15f51c66a52",
    "support"
   ],
   "common/namespaces.js": [
    "a8018fb9fb6f1f2212f5433581fc12e7795a638e",
    "support"
   ],
   "common/object-association.js": [
-   "c6955b7bbf00d73ec5959678391aa59d36da8321",
+   "759706842deec7ed3b59c66fab89209bd93cc561",
    "support"
   ],
   "common/object-association.js.headers": [
    "e3593850f8098d3f3ff82c042deab15f51c66a52",
    "support"
   ],
   "common/performance-timeline-utils.js": [
    "8a914a75398a2865da676183a62b00753607fbca",
--- a/testing/web-platform/meta/custom-elements/custom-element-registry/per-global.html.ini
+++ b/testing/web-platform/meta/custom-elements/custom-element-registry/per-global.html.ini
@@ -1,5 +1,4 @@
 [per-global.html]
-  expected: TIMEOUT
   [Discarding the browsing context must not change window.customElements]
     expected: FAIL
 
deleted file mode 100644
--- a/testing/web-platform/meta/html/browsers/history/the-location-interface/per-global.window.js.ini
+++ /dev/null
@@ -1,2 +0,0 @@
-[per-global.window.html]
-  expected: TIMEOUT
--- a/testing/web-platform/tests/common/object-association.js
+++ b/testing/web-platform/tests/common/object-association.js
@@ -9,17 +9,17 @@ window.testIsPerWindow = propertyName =>
     const frame = iframe.contentWindow;
 
     const before = frame[propertyName];
     assert_true(before !== undefined && before !== null, `window.${propertyName} must be implemented`);
 
     iframe.remove();
 
     const after = frame[propertyName];
-    assert_equals(after, before);
+    assert_equals(after, before, `window.${propertyName} should not change after iframe.remove()`);
   }, `Discarding the browsing context must not change window.${propertyName}`);
 
   async_test(t => {
     const iframe = document.createElement("iframe");
     document.body.appendChild(iframe);
     const frame = iframe.contentWindow;
 
     const before = frame[propertyName];
@@ -51,14 +51,16 @@ window.testIsPerWindow = propertyName =>
       const frame = iframe.contentWindow;
       const before = frame[propertyName];
       assert_true(before !== undefined && before !== null, `window.${propertyName} must be implemented`);
 
       frame.document.open();
 
       const after = frame[propertyName];
       assert_not_equals(after, before);
+
+      frame.document.close();
     });
 
     iframe.src = "/common/blank.html";
     document.body.appendChild(iframe);
   }, `document.open() must replace window.${propertyName}`);
 };