Closed Bug 1020910 Opened 10 years ago Closed 10 years ago

Marionette cannot detect correctly detect icons on vertical homescreen

Categories

(Remote Protocol :: Marionette, defect, P1)

x86_64
Linux
defect

Tracking

(Not tracked)

RESOLVED WONTFIX

People

(Reporter: zcampbell, Unassigned)

References

Details

(Keywords: pi-marionette-displayed)

Attachments

(1 file)

Attached file Test case
Marionette interprets all icons on the new homescreen as visible.


Build:
Gaia      d2cfef555dabab415085e548ed44c48a99be5c32
Gecko     https://hg.mozilla.org/mozilla-central/rev/51b428be6213
BuildID   20140604235615
Version   32.0a1
ro.build.version.incremental=eng.cltbld.20140605.031251
ro.build.date=Thu Jun  5 03:13:01 EDT 2014
Dump of test case:
Phone
True
{u'width': 106.66667175292969, u'height': 116.2166748046875}
{u'y': 172.21665954589844, u'x': 0}
Messages
True
{u'width': 106.66667175292969, u'height': 116.21665954589844}
{u'y': 56, u'x': 0}
Contacts
True
{u'width': 106.66665649414062, u'height': 116.21665954589844}
{u'y': 56, u'x': 106.66667175292969}
Browser
True
{u'width': 106.66667175292969, u'height': 116.21665954589844}
{u'y': 56, u'x': 213.3333282470703}
Camera
True
{u'width': 106.66667175292969, u'height': 116.21665954589844}
{u'y': 358.41668701171875, u'x': 0}
Gallery
True
{u'width': 106.66665649414062, u'height': 116.21665954589844}
{u'y': 358.41668701171875, u'x': 106.66667175292969}
FM Radio
True
{u'width': 106.66667175292969, u'height': 116.21665954589844}
{u'y': 358.41668701171875, u'x': 213.3333282470703}
Settings
True
{u'width': 106.66667175292969, u'height': 116.2166748046875}
{u'y': 474.6333312988281, u'x': 0}
Marketplace
True
{u'width': 106.66665649414062, u'height': 116.2166748046875}
{u'y': 474.6333312988281, u'x': 106.66667175292969}
Calendar
True
{u'width': 106.66667175292969, u'height': 116.2166748046875}
{u'y': 474.6333312988281, u'x': 213.3333282470703}
Clock
True
{u'width': 106.66667175292969, u'height': 116.21665954589844}
{u'y': 590.8499755859375, u'x': 0}
Usage
True
{u'width': 106.66665649414062, u'height': 116.21665954589844}
{u'y': 590.8499755859375, u'x': 106.66667175292969}
E-Mail
True
{u'width': 106.66667175292969, u'height': 116.21665954589844}
{u'y': 590.8499755859375, u'x': 213.3333282470703}
Music
True
{u'width': 106.66667175292969, u'height': 116.21665954589844}
{u'y': 707.0499877929688, u'x': 0}
Video
True
{u'width': 106.66665649414062, u'height': 116.21665954589844}
{u'y': 707.0499877929688, u'x': 106.66667175292969}
Built-in Keyboard
True
{u'width': 106.66667175292969, u'height': 116.2166748046875}
{u'y': 893.2666625976562, u'x': 0}
In-app Payment Tester
True
{u'width': 106.66665649414062, u'height': 116.2166748046875}
{u'y': 893.2666625976562, u'x': 106.66667175292969}
Stage
True
{u'width': 106.66667175292969, u'height': 116.2166748046875}
{u'y': 893.2666625976562, u'x': 213.3333282470703}
Mochitest
True
{u'width': 106.66667175292969, u'height': 116.2166748046875}
{u'y': 1009.4666748046875, u'x': 0}
Bookmarks Reader
True
{u'width': 106.66665649414062, u'height': 116.2166748046875}
{u'y': 1009.4666748046875, u'x': 106.66667175292969}
Device Storage Test
True
{u'width': 106.66667175292969, u'height': 116.2166748046875}
{u'y': 1009.4666748046875, u'x': 213.3333282470703}
Demo Keyboard
True
{u'width': 106.66667175292969, u'height': 116.21665954589844}
{u'y': 1125.683349609375, u'x': 0}
Geoloc
True
{u'width': 106.66665649414062, u'height': 116.21665954589844}
{u'y': 1125.683349609375, u'x': 106.66667175292969}
Membuster
True
{u'width': 106.66667175292969, u'height': 116.21665954589844}
{u'y': 1125.683349609375, u'x': 213.3333282470703}
Music2
True
{u'width': 106.66667175292969, u'height': 116.2166748046875}
{u'y': 1241.9000244140625, u'x': 0}
IME Tests
True
{u'width': 106.66665649414062, u'height': 116.2166748046875}
{u'y': 1241.9000244140625, u'x': 106.66667175292969}
Share Receiver
True
{u'width': 106.66667175292969, u'height': 116.2166748046875}
{u'y': 1241.9000244140625, u'x': 213.3333282470703}
Template
True
{u'width': 106.66667175292969, u'height': 116.21665954589844}
{u'y': 1358.0999755859375, u'x': 0}
Test Agent
True
{u'width': 106.66665649414062, u'height': 116.21665954589844}
{u'y': 1358.0999755859375, u'x': 106.66667175292969}
Test Container
True
{u'width': 106.66667175292969, u'height': 116.21665954589844}
{u'y': 1358.0999755859375, u'x': 213.3333282470703}
Test IAC Publisher
True
{u'width': 106.66667175292969, u'height': 116.2166748046875}
{u'y': 1474.316650390625, u'x': 0}
Test IAC Subscriber
True
{u'width': 106.66665649414062, u'height': 116.2166748046875}
{u'y': 1474.316650390625, u'x': 106.66667175292969}
Test OTASP
True
{u'width': 106.66667175292969, u'height': 116.2166748046875}
{u'y': 1474.316650390625, u'x': 213.3333282470703}
Test receiver#1
True
{u'width': 106.66667175292969, u'height': 116.21665954589844}
{u'y': 1590.5333251953125, u'x': 0}
Test Receiver#2
True
{u'width': 106.66665649414062, u'height': 116.21665954589844}
{u'y': 1590.5333251953125, u'x': 106.66667175292969}
Test receiver (inline)
True
{u'width': 106.66667175292969, u'height': 116.21665954589844}
{u'y': 1590.5333251953125, u'x': 213.3333282470703}
Test Wap Push
True
{u'width': 106.66667175292969, u'height': 116.21665954589844}
{u'y': 1706.7333984375, u'x': 0}
UI tests
True
{u'width': 106.66665649414062, u'height': 116.21665954589844}
{u'y': 1706.7333984375, u'x': 106.66667175292969}
UI tests - Privileged App
True
{u'width': 106.66667175292969, u'height': 116.21665954589844}
{u'y': 1706.7333984375, u'x': 213.3333282470703}
Test FxA Client
True
{u'width': 106.66667175292969, u'height': 116.2166748046875}
{u'y': 1822.949951171875, u'x': 0}
Sheet app 1
True
{u'width': 106.66665649414062, u'height': 116.2166748046875}
{u'y': 1822.949951171875, u'x': 106.66667175292969}
Sheet app 2
True
{u'width': 106.66667175292969, u'height': 116.2166748046875}
{u'y': 1822.949951171875, u'x': 213.3333282470703}
Sheet app 3
True
{u'width': 106.66667175292969, u'height': 116.2166748046875}
{u'y': 1939.1500244140625, u'x': 0}
Test Find My Device
True
{u'width': 106.66665649414062, u'height': 116.2166748046875}
{u'y': 1939.1500244140625, u'x': 106.66667175292969}
Google Contacts DS
True
{u'width': 106.66667175292969, u'height': 116.2166748046875}
{u'y': 1939.1500244140625, u'x': 213.3333282470703}
LI Contacts DS
True
{u'width': 106.66667175292969, u'height': 116.21665954589844}
{u'y': 2055.36669921875, u'x': 0}
Attachment #8434883 - Attachment description: vertical_visibility.py → Test case
Summary: Marionette cannot detect visibility of icons on vertical homescreen → Marionette cannot detect correctly detect icons on vertical homescreen
This blocks full testing of the new homescreen, bumping to P1
Priority: -- → P1
Looking at the new vertical homescreen and using the test case provided I would say that Marionette is doing the right thing.

Looking at https://dvcs.w3.org/hg/webdriver/raw-file/tip/webdriver-spec.html#determining-if-an-element-is-displayed, the line that says

> The element MUST NOT be displayed if there is a [css3-2d-transforms] or [css3-3d-transforms] property that gives a negative x or y to the canvas. The User Agent MUST NOT allow negative scrolling.

The wording needs a little tweaking but the gist of that section is 

If there is an element that doesnt have styles that hide it or transform it to a place we can't scroll to then it MUST be considered not displayed. While the elements have transforms that push it down we can scroll to them and then are visible.
I had a chat with Zac about this and I the issue is when an element is outside the viewport. is_displayed() works by checking if it can be scrolled to AND it it doesnt have css that can hide it (display:none, etc)

If you want to check that an element is not in the viewport currently then do the following

> self.marionette.execute_script('return arguments[0].getBoundingClientRect()', [element])

The object returned will have keys top and left. Their value is relative to the viewport top/left

see https://developer.mozilla.org/en-US/docs/Web/API/Element.getBoundingClientRect
Status: NEW → RESOLVED
Closed: 10 years ago
Resolution: --- → WONTFIX
Product: Testing → Remote Protocol
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: