Bug 783589 - Fix for intermittent test_popup-navigates-children.html, test_sibling-matching-parent.html failure. r=jlebar, a=test-only
authorHonza Bambas <honzab.moz@firemni.cz>
Fri, 30 Aug 2013 11:41:10 +0200
changeset 153928 5e3da059fa07ae5f5d20497f1d0cdddbf931c8a6
parent 153927 eb53fd0e98d86f9c9b78025c25b7bdaa036926df
child 153929 91e513122ea5ce0cef838a7bd9b4fe72eebb9210
push id2859
push userakeybl@mozilla.com
push dateMon, 16 Sep 2013 19:14:59 +0000
treeherdermozilla-beta@87d3c51cd2bf [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersjlebar, test-only
bugs783589
milestone25.0a2
Bug 783589 - Fix for intermittent test_popup-navigates-children.html, test_sibling-matching-parent.html failure. r=jlebar, a=test-only
docshell/test/navigation/NavigationUtils.js
testing/mochitest/android.json
testing/mochitest/androidx86.json
--- a/docshell/test/navigation/NavigationUtils.js
+++ b/docshell/test/navigation/NavigationUtils.js
@@ -179,18 +179,22 @@ function xpcWaitForFinishedFrames(callba
   function searchForFinishedFrames(win) {
     if ((escape(unescape(win.location)) == escape(target_url) ||
          escape(unescape(win.location)) == escape(target_popup_url)) && 
         win.document && 
         win.document.body && 
         (win.document.body.textContent == body ||
          win.document.body.textContent == popup_body) && 
         win.document.readyState == "complete") {
-      if (!contains(win, finishedWindows)) {
-        finishedWindows.push(win);
+
+      var util = win.QueryInterface(SpecialPowers.Ci.nsIInterfaceRequestor)
+                    .getInterface(SpecialPowers.Ci.nsIDOMWindowUtils);
+      var windowId = util.outerWindowID;
+      if (!contains(windowId, finishedWindows)) {
+        finishedWindows.push(windowId);
         frameFinished();
       }
     }
     for (var i = 0; i < win.frames.length; i++)
       searchForFinishedFrames(win.frames[i]);
   }
 
   function poll() {
--- a/testing/mochitest/android.json
+++ b/testing/mochitest/android.json
@@ -103,17 +103,16 @@
  "content/media/test/test_buffered.html": "",
  "content/media/webspeech/synth/ipc/test/test_ipc.html": "bug 857673",
  "content/media/webspeech/recognition/test/test_nested_eventloop.html": "",
  "content/smil/test/test_smilRepeatTiming.xhtml": "TIMED_OUT",
  "content/smil/test/test_smilExtDoc.xhtml": "",
  "content/xul/content/test/test_bug486990.xul": "TIMED_OUT",
  "docshell/test/navigation/test_bug13871.html": "RANDOM",
  "docshell/test/navigation/test_bug430723.html": "TIMED_OUT",
- "docshell/test/navigation/test_popup-navigates-children.html": "bug 783589",
  "docshell/test/navigation/test_sessionhistory.html": "RANDOM",
  "docshell/test/navigation/test_bug344861.html": "",
  "docshell/test/test_bug94514.html": "TIMED_OUT",
  "docshell/test/test_bug413310.html": "",
  "docshell/test/test_bug590573.html": "bug 823022",
  "docshell/test/test_bug598895.html": "",
  "docshell/test/test_bug637644.html": "",
  "docshell/test/test_bug668513.html": "RANDOM",
--- a/testing/mochitest/androidx86.json
+++ b/testing/mochitest/androidx86.json
@@ -106,17 +106,16 @@
  "content/media/webaudio/test/test_scriptProcessorNodeChannelCount.html": "bug 865642",
  "content/media/webspeech/synth/ipc/test/test_ipc.html": "bug 857673",
  "content/media/webspeech/recognition/test/test_nested_eventloop.html": "",
  "content/smil/test/test_smilRepeatTiming.xhtml": "TIMED_OUT",
  "content/smil/test/test_smilExtDoc.xhtml": "",
  "content/xul/content/test/test_bug486990.xul": "TIMED_OUT",
  "docshell/test/navigation/test_bug13871.html": "RANDOM",
  "docshell/test/navigation/test_bug430723.html": "TIMED_OUT",
- "docshell/test/navigation/test_popup-navigates-children.html": "bug 783589",
  "docshell/test/navigation/test_sessionhistory.html": "RANDOM",
  "docshell/test/navigation/test_bug344861.html": "",
  "docshell/test/test_bug94514.html": "TIMED_OUT",
  "docshell/test/test_bug413310.html": "",
  "docshell/test/test_bug590573.html": "bug 823022",
  "docshell/test/test_bug598895.html": "",
  "docshell/test/test_bug637644.html": "",
  "docshell/test/test_bug668513.html": "RANDOM",