Intermittent browser_bug343515.js | Tab 2 should have 2 iframes - Got 1, expected 2 | uncaught JS exception ... | Test timed out

RESOLVED FIXED in mozilla19

Status

()

defect
RESOLVED FIXED
7 years ago
6 years ago

People

(Reporter: emorley, Assigned: Felipe)

Tracking

({intermittent-failure})

Trunk
mozilla19
x86
Windows XP
Points:
---
Dependency tree / graph

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(2 attachments)

Rev3 WINNT 5.1 mozilla-inbound opt test mochitest-other on 2012-06-14 19:58:14 PDT for push 36e3e2913c3d

slave: talos-r3-xp-005

https://tbpl.mozilla.org/php/getParsedLog.php?id=12683765&tree=Mozilla-Inbound

{
TEST-PASS | chrome://mochitests/content/browser/docshell/test/navigation/browser_bug343515.js | Tab 2 should be inactive
TEST-UNEXPECTED-FAIL | chrome://mochitests/content/browser/docshell/test/navigation/browser_bug343515.js | Tab 2 should have 2 iframes - Got 1, expected 2
Stack trace:
    JS frame :: chrome://mochikit/content/browser-test.js :: test_is :: line 428
    JS frame :: chrome://mochitests/content/browser/docshell/test/navigation/browser_bug343515.js :: step4 :: line 134
    JS frame :: chrome://mochitests/content/browser/docshell/test/navigation/browser_bug343515.js :: frameLoadCallback :: line 56
    JS frame :: chrome://mochitests/content/browser/docshell/test/navigation/browser_bug343515.js :: frameLoadCallback :: line 49
    JS frame :: chrome://mochitests/content/browser/docshell/test/navigation/browser_bug343515.js :: frameLoadCallback :: line 49
    JS frame :: chrome://mochikit/content/browser-test.js :: <TOP_LEVEL> :: line 459

TEST-PASS | chrome://mochitests/content/browser/docshell/test/navigation/browser_bug343515.js | Tab 2 iframe 0 should have 1 iframes
TEST-PASS | chrome://mochitests/content/browser/docshell/test/navigation/browser_bug343515.js | Tab2 iframe 0 should be inactive
TEST-PASS | chrome://mochitests/content/browser/docshell/test/navigation/browser_bug343515.js | Tab2 iframe 0 subiframe 0 should be inactive
TEST-UNEXPECTED-FAIL | chrome://mochitests/content/browser/docshell/test/navigation/browser_bug343515.js | an unexpected uncaught JS exception reported through window.onerror - TypeError: aWindow is undefined at chrome://mochitests/content/browser/docshell/test/navigation/browser_bug343515.js:9
Stack trace:
    JS frame :: chrome://mochikit/content/tests/SimpleTest/SimpleTest.js :: simpletestOnerror :: line 994
    native frame :: <unknown filename> :: <TOP_LEVEL> :: line 0

TEST-INFO | chrome://mochitests/content/browser/docshell/test/navigation/browser_bug343515.js | Console message: [JavaScript Error: "TypeError: aWindow is undefined" {file: "chrome://mochitests/content/browser/docshell/test/navigation/browser_bug343515.js" line: 9}]
TEST-INFO | chrome://mochitests/content/browser/docshell/test/navigation/browser_bug343515.js | Console message: [JavaScript Error: "The character encoding of the HTML document was not declared. The document will render with garbled text in some browser configurations if the document contains characters from outside the US-ASCII range. The character encoding of the page must to be declared in the document or in the transfer protocol." {file: "http://mochi.test:8888/browser/docshell/test/navigation/bug343515_pg3.html" line: 0}]
TEST-UNEXPECTED-FAIL | chrome://mochitests/content/browser/docshell/test/navigation/browser_bug343515.js | Test timed out
args: ['c:\\talos-slave\\test\\build\\bin\\screenshot.exe', 'c:\\docume~1\\cltbld\\locals~1\\temp\\mozilla-test-fail_mt3uve']
SCREENSHOT: <snip>
INFO TEST-END | chrome://mochitests/content/browser/docshell/test/navigation/browser_bug343515.js | finished in 30032ms
TEST-UNEXPECTED-FAIL | chrome://mochitests/content/browser/docshell/test/navigation/browser_bug343515.js | Found a tab after previous test timed out: http://mochi.test:8888/browser/docshell/test/navigation/bug343515_pg3.html
TEST-UNEXPECTED-FAIL | chrome://mochitests/content/browser/docshell/test/navigation/browser_bug343515.js | Found a tab after previous test timed out: http://mochi.test:8888/browser/docshell/test/navigation/bug343515_pg1.html
}
I don't really recall why I'm CCed on this bug, but it's not in any code that I work on, so I'm unlikely to ever do anything about it. :-(
Ed points out that I actually wrote this test long ago. :-)
This never got full review - see bug 343515#c45. Naughty naughty Dolske. ;-)

There were a couple of things wrong here:
1 - The whole recursive frame load waiting thing was totally unnecessary. Load
doesn't fire on the window until all descendant iframes have loaded.

2 - The chrome event handler wasn't filtering by target, which it should. This
is probably to blame for the intermittent orange.

3 - Setting window.location during document load actually invokes
window.location.replace.

4 - Session history navigation seems to have weird behavior when called from
an onload handler. I wanted to investigate this further, but I've already spent
too much time on this. SimpleTest.executeSoon() seems to do the trick here.
Attachment #677736 - Flags: review?(dolske)
Comment on attachment 677736 [details] [diff] [review]
Bug 765192 - Fix broken test. v1

Review of attachment 677736 [details] [diff] [review]:
-----------------------------------------------------------------

I don't see anything obviously terrible. Ahem.
Attachment #677736 - Flags: review?(dolske) → review+
Hrmph, well I guess that suggests this didn't fix it? Blarg.
https://hg.mozilla.org/mozilla-central/rev/6fec70b5b508
Status: NEW → RESOLVED
Closed: 7 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla19
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
Blocks: 813242
Since the issue has morhped, filed bug 813242 for the new one; closing this.
Status: REOPENED → RESOLVED
Closed: 7 years ago7 years ago
Resolution: --- → FIXED
Assignee: nobody → bobbyholley+bmo
Whiteboard: [orange]
I may need to back this out to fix Bug 825544.
(In reply to Olli Pettay [:smaug] from comment #105)
> I may need to back this out to fix Bug 825544.

This is only a test change to make behavior more defined. Rather than backing it out, can you just update the test so that it passes given whatever navigation behavior you decide?
I need to backout so much in order to fix Bug 825544, that I really don't want to make
any changes. (Bug 825544 needs to be fixed in beta too.)
Also, why does this need to be backed out? The primary relevant to that bug is that this test _avoids_ navigating via window.location because of the weirdness of the bug in question. So it seems like this test should make things agnostic to the bug you're backing out.
because the backout will bring back the old behavior where .setAttribute("src", href) has the
same behavior as location = href
(In reply to Olli Pettay [:smaug] from comment #109)
> because the backout will bring back the old behavior where
> .setAttribute("src", href) has the
> same behavior as location = href

Oh, I see. I thought that bug only affected nsLocation. My bad.
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
Whiteboard: [disable-me 2013-04-01]