Bug 1375833 - Part 4.1: Revert test_bug123696.html & update file_bug1326251.html. r=smaug
authorSamael Wang <freesamael@gmail.com>
Mon, 21 Aug 2017 18:28:53 +0800
changeset 377240 e56d79b257ac134c1f2094b34629ecacd282b313
parent 377239 73747f26f74e515acf479cb7861fd293775b123f
child 377241 8a5a636429ea000a738efd1d9189c2a5b696de8d
push id49807
push userryanvm@gmail.com
push dateMon, 28 Aug 2017 13:45:50 +0000
treeherderautoland@8a5a636429ea [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerssmaug
bugs1375833, 123696, 1326251
milestone57.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 1375833 - Part 4.1: Revert test_bug123696.html & update file_bug1326251.html. r=smaug Revert test_bug123696.html to what it was before bug 1326251 laned. Update file_bug1326251.html to reflect the change that static frame entries won't be cleared on reloading. MozReview-Commit-ID: F93ZBNv1Gj
docshell/test/navigation/file_bug1326251.html
docshell/test/test_bug123696.html
--- a/docshell/test/navigation/file_bug1326251.html
+++ b/docshell/test/navigation/file_bug1326251.html
@@ -116,37 +116,37 @@
         opener.is(shistory.index, 4, 'shistory.index');
         opener.is(history.length, 6, 'history.length');
         let staticFrame = document.getElementById('staticFrame');
         let innerStaticFrame = staticFrame.contentDocument.getElementById('staticFrame');
         opener.is(innerStaticFrame.contentDocument.location.href, BASE_URL + 'frame1.html', 'innerStaticFrame location');
         opener.ok(!staticFrame.contentDocument.getElementById('dynamicFrame'), 'innerDynamicFrame should not exist');
 
         // Test 6: Insert and navigate inner dynamic frame and then reload outer
-        // frame. Verify that inner frame entries are all removed.
+        // frame. Verify that inner dynamic frame entries are all removed.
         staticFrame.width = '320px';
         staticFrame.height = '360px';
         let innerDynamicFrame = await createDynamicFrame(staticFrame.contentDocument, 'frame2.html');
         await loadUriInFrame(innerDynamicFrame, 'frame3.html');
         // staticFrame:       frame0 -> frame1 -> frame2 -> iframe_static
         // innerStaticFrame:                                frame0        -> frame1
         // innerDynamicFrame:                                                frame2 -> frame3
         opener.is(shistory.index, 5, 'shistory.index');
         opener.is(history.length, 6, 'history.length');
         let staticFrameLoadPromise = new Promise(resolve => {
           staticFrame.onload = resolve;
         });
         staticFrame.contentWindow.location.reload();
         await staticFrameLoadPromise;
         // staticFrame:       frame0 -> frame1 -> frame2 -> iframe_static
-        // innerStaticFrame:                                frame0
-        opener.is(shistory.index, 3, 'shistory.index');
-        opener.is(history.length, 4, 'history.length');
+        // innerStaticFrame:                                frame0        -> frame1
+        opener.is(shistory.index, 4, 'shistory.index');
+        opener.is(history.length, 5, 'history.length');
         innerStaticFrame = staticFrame.contentDocument.getElementById('staticFrame');
-        opener.is(innerStaticFrame.contentDocument.location.href, BASE_URL + 'frame0.html', 'innerStaticFrame location');
+        opener.is(innerStaticFrame.contentDocument.location.href, BASE_URL + 'frame1.html', 'innerStaticFrame location');
         opener.ok(!staticFrame.contentDocument.getElementById('dynamicFrame'), 'innerDynamicFrame should not exist');
         opener.nextTest();
         window.close();
       }
     ];
 
     function awaitOnload(frame, occurances=1) {
       return new Promise(function(resolve, reject) {
--- a/docshell/test/test_bug123696.html
+++ b/docshell/test/test_bug123696.html
@@ -24,18 +24,18 @@ SimpleTest.waitForExplicitFinish();
 
 function finishTest() {
   is(window.frames[0].frames[0].document.documentElement.textContent,
      "change2", "Reload should have reloaded correctly!");
   SimpleTest.finish();
 }
 
 function doReload() {
-  window.frames[0].frames[0].frameElement.onload = finishTest;
-  window.frames[0].frames[0].location.reload();
+  window.frames[0].frameElement.onload = finishTest;
+  window.frames[0].location.reload();
 }
 
 addLoadEvent(function() {
   window.frames[0].frames[0].frameElement.onload = doReload;
   window.frames[0].frames[0].frameElement.src = "javascript:parent.change2()";
 });