Closed Bug 1111568 Opened 10 years ago Closed 7 years ago

Test failure 'Number of visible rows should equal 6' in /testAwesomeBar/testVisibleItemsMax.js

Categories

(Mozilla QA Graveyard :: Mozmill Tests, defect, P2)

x86
Linux
defect

Tracking

(firefox35 disabled, firefox36 disabled, firefox37 disabled, firefox38 disabled)

RESOLVED INVALID
Tracking Status
firefox35 --- disabled
firefox36 --- disabled
firefox37 --- disabled
firefox38 --- disabled

People

(Reporter: mihaelav, Unassigned)

References

()

Details

(Whiteboard: [mozmill-test-failure][mozmill-test-skipped] [sprint])

Attachments

(3 files)

Module:    testVisibleItemsMax
Test:      /testAwesomeBar/testVisibleItemsMax.js
Failure:   Number of visible rows should equal 6
Branches:  Nightly (37.0a1), Aurora (36.0a2)
Platforms: Ubuntu 14.04

Reports:
http://mozmill-daily.blargon7.com/#/functional/failure?app=Firefox&branch=All&platform=All&from=2014-12-08&to=2014-12-15&test=%2FtestAwesomeBar%2FtestVisibleItemsMax.js&func=testVisibleItemsMax
This failed for 18 times for with the latest beta spin on Ubuntu 14.04 nodes, it should be skipped.
Attached patch skip-patch betaSplinter Review
Here is the skip patch for beta.
Attachment #8542536 - Flags: review?(andreea.matei)
Comment on attachment 8542536 [details] [diff] [review]
skip-patch beta

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

We need to figure out what's different for 14.04 machines.

http://hg.mozilla.org/qa/mozmill-tests/rev/05d3a0ce4f5d (beta)
Attachment #8542536 - Flags: review?(andreea.matei) → review+
Whiteboard: [mozmill-test-failure]
Whiteboard: [mozmill-test-failure] → [mozmill-test-failure][mozmill-test-skipped]
Assignee: nobody → andreea.matei
Status: NEW → ASSIGNED
We decided to skip this test on mozilla-beta, because of multiple failures. Attached is the skip patch.
Attachment #8548151 - Flags: review?(andreea.matei)
Comment on attachment 8548151 [details] [diff] [review]
skipvsblitems.patch

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

http://hg.mozilla.org/qa/mozmill-tests/rev/1cf1e0c36b25 (beta)
Attachment #8548151 - Flags: review?(andreea.matei) → review+
Haven't reproduced this on a local Ubuntu 14.04 machine with or locale in over 50 runs. I'll try on a staging machine.
Assignee: andreea.matei → mihaela.velimiroviciu
Whiteboard: [mozmill-test-failure][mozmill-test-skipped] → [mozmill-test-failure][mozmill-test-skipped] [sprint]
I reproduced this intermittently on staging and locally, but only if the tests from other folders (remote, addons) are ran before it. I'm working on finding a smaller amount of tests which help reproduce this when they run.
The failure isn't reproducing when running the testVisibleItemsMax.js alone. It reproduces intermittently by running the testSwitchToTab.js test before. 
The problem is that, for some reason, the autocomplete results popup list doesn't have the expected height the time: sometimes, it shows only 1 or 2 entries, the rest being visible only by dragging the scrollbar. 

I'm not sure where else to look on our side. Maybe it's a Firefox bug eventually...?
This was really hard to track, but I finally figured it out. The issue we have here is related to the fact that the autocomple richlistbox element's height is computed programmatically, this is the code at fault: http://hg.mozilla.org/mozilla-central/rev/0fc382c36b4c. I actually have past front-end development experience, and I'm acquainted with this approach, and from my experience something like this will not always work when it's automated, and I will take the liberty to say that this is not related to firefox, but to all major browsers.
What happens here: 1st. we run the testSwitchToTab.js, that opens/closes multiple times in a sequence so fast that the code which computes the auto complete popup height fails to finish, this is a matter of milliseconds, this results in the auto complete popup becoming kinda 'broken' with an incorrect height value, we are testing the auto complete popup height in testVisibleItemsMax.js, this is why this test fails only when it's run together with the previous one.

One thing we can do here is to place testVisibleItemsMax.js before testSwitchToTab.js => imho bad approach which will just mean that we are running from the problem instead of fixing it.

What I decided to do, was investigating some of the firefox code to see if there is something we miss in toolbars.js, so I discovered that there are some event listeners that have not been implemented in toolbars.js. I treated those resulting in a big drop in the failure rate, but this still didn't fixed fully the problem, I had no choice but to add a small sleep of 300ms in order to fix all the failures. One of my ideas besides this approach was to wait for the height attribute to change for the autocomplete richlistbox element, this is impossible to implement because, between one instance of autocomplete being open and the next one this value may be the same, so we don't have a way to predict if opening an automplete instance after another will result in a height change.

So my final conclusion: this is not a Firefox bug, imo this is impossible to reproduce manually, unless you're a super saiyan with too much time on your hands and the only thing you like to do with your computer and web browser is to open/close the autocomplete popup multiple times.
Assignee: mihaela.velimiroviciu → teodor.druta
Attachment #8563468 - Flags: review?(mihaela.velimiroviciu)
Attachment #8563468 - Flags: review?(andreea.matei)
Attachment #8563468 - Flags: feedback?(hskupin)
Attachment #8563468 - Flags: review?(mihaela.velimiroviciu) → review+
Comment on attachment 8563468 [details] [diff] [review]
fix_visible_items.patch

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

lgtm
Attachment #8563468 - Flags: review?(andreea.matei) → review+
Well, the fix was provided everything was explained in comment #14. :(
Assignee: teodor.druta → nobody
Status: ASSIGNED → NEW
Sadly this test was not skipped on default and aurora yet. So I transplanted the skip patch now.

https://hg.mozilla.org/qa/mozmill-tests/rev/724ddaa47716 (default)
https://hg.mozilla.org/qa/mozmill-tests/rev/69146a64c745 (aurora)
Comment on attachment 8563468 [details] [diff] [review]
fix_visible_items.patch

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

We are most likely not going to get this fix landed. Instead we want to make sure all works fine for the Marionette tests directly. We simply want to reduce possible test failures here.
Attachment #8563468 - Flags: feedback?(hskupin) → feedback-
I will keep this bug open until we have a Firefox UI test replacement.
Mozmill tests have been superseded by Marionette tests.
Status: NEW → RESOLVED
Closed: 7 years ago
Resolution: --- → INVALID
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: