Closed Bug 609062 Opened 14 years ago Closed 14 years ago

Timeout failure in testAccessLocationBarHistory

Categories

(Mozilla QA Graveyard :: Mozmill Tests, defect)

defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: u279076, Assigned: aaronmt)

References

()

Details

(Whiteboard: [mozmill-branch-fail][mozmill-test-failure])

Attachments

(1 file, 1 obsolete file)

MODULE: testAwesomeBar/testAccessLocationBar.js
TEST: testAccessLocationBarHistory
ERROR: Timeout exceeded for waitForElement ID: mozilla_logo
BRANCH: mozilla1.9.1
PLATFORM: Windows, Linux
Blocks: 604718
Whiteboard: [mozmill-branch-fail]
Summary: Timeout failure in testAwesomebar/testAccessLocationBar.js → Timeout failure in testAccessLocationBarHistory
Whiteboard: [mozmill-branch-fail] → [mozmill-branch-fail][mozmill-test-failure]
Assignee: nobody → aaron.train
This is weird, after a wait for page load we sometimes don't get a valid reference to elements on the page.
waitForPageLoad on line 94 - http://hg.mozilla.org/qa/mozmill-tests/file/ac1a4b9dc91a/firefox/testAwesomeBar/testAccessLocationBar.js#l94

and test failure right after with

waitForElement on line 99 - http://hg.mozilla.org/qa/mozmill-tests/file/ac1a4b9dc91a/firefox/testAwesomeBar/testAccessLocationBar.js#l99

When this test fails, the reference mozillaLogo is null
Status: NEW → ASSIGNED
The test seems to get a valid reference to the elements on the page when we
load the page with the go button over pressing enter on the selected result in
the autocomplete menu. Strange.
(In reply to comment #3)
> The test seems to get a valid reference to the elements on the page when we
> load the page with the go button over pressing enter on the selected result in
> the autocomplete menu. Strange.

Knowing that, we should probably be testing both methods in this test.  If it is reproducible manually, this points to a Firefox bug.
(In reply to comment #4)
> (In reply to comment #3)
> > The test seems to get a valid reference to the elements on the page when we
> > load the page with the go button over pressing enter on the selected result in
> > the autocomplete menu. Strange.
> 
> Knowing that, we should probably be testing both methods in this test.  If it
> is reproducible manually, this points to a Firefox bug.

Not reproducible manually. It's a racing condition, as mentioned it sometimes happens. Henrik, any idea here looking back at 1.9.1?
The strange thing is that this bug doesn't happen on OS X but on any other platform. When I add a timeout of 100ms it surprisingly passes. It doesn't make any sense.
This is a Mozmill bug and will be fixed with bug 610134.
Assignee: aaron.train → hskupin
Whiteboard: [mozmill-branch-fail][mozmill-test-failure] → [mozmill-branch-fail][mozmill-test-failure][will be fixed by bug 610134]
The fix on bug 610134 will not fix this particular failure. The reason why we are failing here is that the web page selected via the autocomplete list gets loaded delayed after pressing return. waitForPageLoad kicks in too early, means it waits for the already loaded about:blank page.

So what we should probably do here is to wait for the correct value in the locationbar and right after calling waitForPageLoad.

Handing back to Aaron.
Assignee: hskupin → aaron.train
No longer depends on: 610134
Whiteboard: [mozmill-branch-fail][mozmill-test-failure][will be fixed by bug 610134] → [mozmill-branch-fail][mozmill-test-failure]
So I'm looking at this just now, it seems like we don't get a value for the currently shown URL off the urlbar, remains undefined, and waiting for that value to change doesn't happen. Possible toolbars.js API issue?
(In reply to comment #9)
> So I'm looking at this just now, it seems like we don't get a value for the
> currently shown URL off the urlbar, remains undefined, and waiting for that
> value to change doesn't happen. Possible toolbars.js API issue?

Fixed with bug 612398.

As for this, I'm waiting for the correct value in the currently shown URL after the waitForPageLoad but it doesn't seem to do the trick. The timeout will still occur while waiting for the element.
Simply add dump statements to the test to get useful information logged to the console. That's kinda helpful for tracking issues like that.
Move of Mozmill Test related project bugs to newly created components. You can
filter out those emails by using "Mozmill-Tests-to-MozillaQA" as criteria.
Product: Testing → Mozilla QA
Can we get some progress on it please? While doing release tests for 3.5.16 this test failed on all platforms.
I suggest changing this test to using a click on the go button rather than pressing return. As you mentioned in comment #8, waitForPageLoad kicks in too early. I took your suggestion, and the problem remains in comment #10. I suggest comment #3, unless you have another idea?
Shawn, any suggestions? This is a test dealing with location bar history on the 1.9.1 branch. The gist of it is, we press enter on a URL and sometimes don't get a valid reference to elements on the page. There doesn't seem to be an issue clicking the Go button as a workaround. See comment #3, and comment #8
Nothing in particular comes to mind.  This is only happening on 1.9.1 and not anything newer?
Yeah, 1.9.1
Attached patch Patch v1 - (1.9.1) (obsolete) — Splinter Review
Going with comment #14 for a fix for this
Attachment #493073 - Flags: review?(hskupin)
Comment on attachment 493073 [details] [diff] [review]
Patch v1 - (1.9.1)

We have the toolbars module to get elements.

Also it's an old branch we probably don't support that long anymore, so I'm fine with using the go button here.
Attachment #493073 - Flags: review?(hskupin) → review-
Attachment #493073 - Attachment is obsolete: true
Attachment #493251 - Flags: review?(hskupin)
Attachment #493251 - Flags: review?(hskupin) → review+
Landed as http://hg.mozilla.org/qa/mozmill-tests/rev/8530a6bbf1b0
Status: ASSIGNED → RESOLVED
Closed: 14 years ago
Resolution: --- → FIXED
Product: Mozilla QA → Mozilla QA Graveyard
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: