Bug 765192 - Add some debugging info for browser_bug343515.js r=me
authorFelipe Gomes <felipc@gmail.com>
Thu, 09 May 2013 22:16:49 -0300
changeset 142412 73316004a0494bdd91752a0053fa3f6ac906f74a
parent 142411 8f2977671264601d89a3ef0a93bab91a8d3467b6
child 142413 397da5eb63b23d9b76a3b2f38b9c74dd30f2efac
push id2579
push userakeybl@mozilla.com
push dateMon, 24 Jun 2013 18:52:47 +0000
treeherdermozilla-beta@b69b7de8a05a [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersme
bugs765192, 343515
milestone23.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 765192 - Add some debugging info for browser_bug343515.js r=me
docshell/test/navigation/browser_bug343515.js
--- a/docshell/test/navigation/browser_bug343515.js
+++ b/docshell/test/navigation/browser_bug343515.js
@@ -82,16 +82,18 @@ function step1() {
   // Open a New Tab
   ctx.tab1 = gBrowser.addTab(testPath + "bug343515_pg1.html");
   ctx.tab1Browser = gBrowser.getBrowserForTab(ctx.tab1);
   ctx.tab1Window = ctx.tab1Browser.contentWindow;
   oneShotListener(ctx.tab1Browser, "load", step2);
 }
 
 function step2() {
+  is(testPath + "bug343515_pg1.html", ctx.tab1Browser.currentURI.spec,
+     "Got expected tab 1 url in step 2");
 
   // Our current tab should still be active
   ok(isActive(ctx.tab0Window), "Tab 0 should still be active");
   ok(!isActive(ctx.tab1Window), "Tab 1 should not be active");
 
   // Switch to tab 1
   gBrowser.selectedTab = ctx.tab1;
 
@@ -102,41 +104,49 @@ function step2() {
   // Open another tab
   ctx.tab2 = gBrowser.addTab(testPath + "bug343515_pg2.html");
   ctx.tab2Browser = gBrowser.getBrowserForTab(ctx.tab2);
   ctx.tab2Window = ctx.tab2Browser.contentWindow;
   oneShotListener(ctx.tab2Browser, "load", frameLoadWaiter(ctx.tab2Window, step3));
 }
 
 function step3() {
+  is(testPath + "bug343515_pg2.html", ctx.tab2Browser.currentURI.spec,
+     "Got expected tab 2 url in step 3");
 
   // Tab 0 should be inactive, Tab 1 should be active
   ok(!isActive(ctx.tab0Window), "Tab 0 should be inactive");
   ok(isActive(ctx.tab1Window), "Tab 1 should be active");
 
   // Tab 2's window _and_ its iframes should be inactive
   ok(!isActive(ctx.tab2Window), "Tab 2 should be inactive");
   is(ctx.tab2Window.frames.length, 2, "Tab 2 should have 2 iframes");
+  for (var i = 0; i < ctx.tab2Window.frames.length; i++)
+    info("step 3, frame " + i + " info: " + ctx.tab2Window.frames[i].location);
   ok(!isActive(ctx.tab2Window.frames[0]), "Tab2 iframe 0 should be inactive");
   ok(!isActive(ctx.tab2Window.frames[1]), "Tab2 iframe 1 should be inactive");
 
   // Navigate tab 2 to a different page
   ctx.tab2Window.location = testPath + "bug343515_pg3.html";
   oneShotListener(ctx.tab2Browser, "load", frameLoadWaiter(ctx.tab2Window, step4));
 }
 
 function step4() {
+  is(testPath + "bug343515_pg3.html", ctx.tab2Browser.currentURI.spec,
+     "Got expected tab 2 url in step 4");
 
   // Tab 0 should be inactive, Tab 1 should be active
   ok(!isActive(ctx.tab0Window), "Tab 0 should be inactive");
   ok(isActive(ctx.tab1Window), "Tab 1 should be active");
 
   // Tab2 and all descendants should be inactive
   ok(!isActive(ctx.tab2Window), "Tab 2 should be inactive");
   is(ctx.tab2Window.frames.length, 2, "Tab 2 should have 2 iframes");
+  for (var i = 0; i < ctx.tab2Window.frames.length; i++)
+    info("step 4, frame " + i + " info: " + ctx.tab2Window.frames[i].location);
   is(ctx.tab2Window.frames[0].frames.length, 1, "Tab 2 iframe 0 should have 1 iframes");
   ok(!isActive(ctx.tab2Window.frames[0]), "Tab2 iframe 0 should be inactive");
   ok(!isActive(ctx.tab2Window.frames[0].frames[0]), "Tab2 iframe 0 subiframe 0 should be inactive");
   ok(!isActive(ctx.tab2Window.frames[1]), "Tab2 iframe 1 should be inactive");
 
   // Switch to Tab 2
   gBrowser.selectedTab = ctx.tab2;