Closed
Bug 833061
Opened 11 years ago
Closed 11 years ago
tap() not working correctly on ftu button
Categories
(Remote Protocol :: Marionette, defect)
Tracking
(Not tracked)
RESOLVED
WORKSFORME
People
(Reporter: mdas, Unassigned)
References
Details
Attachments
(1 file)
1.51 KB,
text/plain
|
Details |
In https://github.com/mozilla/gaia-ui-tests/pull/279, the tap() gesture on the Change button in the timezone selection page of ftu is not working (https://github.com/mozilla/gaia-ui-tests/pull/279#discussion_r2674100). The odd thing is, I can confirm that the events sent from marionette to the window are the exact same as those sent if I physically tapped the screen aon that button (touchstart/touchend/mousedown/mouseup/click). Perhaps we're tapping the wrong element? I added a tap to the first button with class name 'change icon icon-dialog', but that doesn't seem to help.
Reporter | ||
Comment 1•11 years ago
|
||
I've been testing this by adding an id to the button we want to interact with. I can see that tap() is successfully dispatching touchevents to the window, so this doesn't seem like a problem with marionette. It may be that buttons of these type have something on them that prevent us from tapping or clicking on them... It seems that buttons with class 'icon' will have pointer-events set to none, so it's never the target of mouse events. I'm not sure if this is related to why our tap (which is touch/mouse/click events) or our click (which is the DOM click() method) don't work. I've tried setting pointer-events to auto, but this doesn't get us any closer. I think we'll need to get the gaia dev who wrote ftu on this bug to help us resolve how we can do test automation on these buttons.
Comment 2•11 years ago
|
||
Fernando, Francisco, can either/both of you help, here? Thanks :-)
Reporter | ||
Comment 3•11 years ago
|
||
So it turns out we have to dispatch events to the tz-region element, but still, I get no results. I can confirm that we're dispatching touchevents to that page, and it should work, but in this case, it just isn't. FYI, for the testing folk, this element is not visible, and our standard automation calls like click/tap don't allow for us to interact with non-visible elements due to the browser automation spec(https://dvcs.w3.org/hg/webdriver/raw-file/tip/webdriver-spec.html#clicking, this is for clicking, but touch events are the same), so our standard tap() and click() commands won't work here, but I've been testing with tap/click commands that don't check visibility and just dispatch the event regardless. I can add this type of method to the gaia-ui-test framework to let us do this, so we shouldn't worry about it being visible or not.
Comment 4•11 years ago
|
||
Sounds a bit of a dirty work-around :(
Reporter | ||
Comment 5•11 years ago
|
||
(In reply to Zac C (:zac) from comment #4) > Sounds a bit of a dirty work-around :( Yeah, I'm not sure why the thing we want to click is non-visible. It'd be much more helpful if the listener was on the actual visible button.
Comment 6•11 years ago
|
||
We have now another very similar test case which involves tapping on a select box (or fake-select box) in the Settings app. In the same as comment #1 of this bug I've tried tapping on numerous other elements in and around to try and trigger the select box to be opened but to no avail. This is high priority as it surrounds changing the Language of Gaia.
Reporter | ||
Updated•11 years ago
|
Reporter | ||
Comment 7•11 years ago
|
||
I just replaced all the click commands with tap and it all works now. I think it is safe to transition the ftu app to tap() now. Reopen if you still see issues please!
Status: NEW → RESOLVED
Closed: 11 years ago
Resolution: --- → WORKSFORME
Comment 8•11 years ago
|
||
Hi Malini, I still can see this issue. Now in the FTU app neither click() or tap() work in the "Date & Time" screen The locators did not changed and the elements are still visibile. Here is what I see in logcat: D/wpa_supplicant( 5372): nl80211: survey data missing! I/Gecko ( 5233): 1376491812074 Marionette TRACE Got: {"using": "css selector", "session": "6-b2g", "type": "findElement", "value": "#time-form li:nth-child(1) > .change.icon.icon-dialog", "to": "0"} I/Gecko ( 5233): 1376491812100 Marionette INFO sendToClient: {"from":"0","value":"{8b1d673c-b65a-4bc0-a546-b9b179f47eac}"}, {b6657c7d-f8ef-4eda-aa68-891fc8a3a7e5}, {b6657c7d-f8ef-4eda-aa68-891fc8a3a7e5} I/Gecko ( 5233): 1376491812111 Marionette TRACE Got: {"element": "{8b1d673c-b65a-4bc0-a546-b9b179f47eac}", "to": "0", "session": "6-b2g", "y": null, "x": null, "type": "singleTap"} I/Gecko ( 5347): Marionette: emitting Touch event of type touchstart to element with id: and tag name: BUTTON at coordinates (250, 234) relative to the viewport I/Gecko ( 5347): Marionette: emitting Touch event of type touchend to element with id: and tag name: BUTTON at coordinates (250, 234) relative to the viewport I/Gecko ( 5347): Marionette: emitting Mouse event of type mousemove at coordinates (250, 234) relative to the viewport I/Gecko ( 5347): Marionette: emitting Mouse event of type mousedown at coordinates (250, 234) relative to the viewport I/Gecko ( 5347): Marionette: emitting Mouse event of type mouseup at coordinates (250, 234) relative to the viewport I/Gecko ( 5233): 1376491812196 Marionette INFO sendToClient: {"from":"0","ok":true}, {92ea99fc-7e3a-4412-abd9-0c9508244b17}, {92ea99fc-7e3a-4412-abd9-0c9508244b17} D/wpa_supplicant( 5372): nl80211: survey data missing! I can see this on: Gecko http://hg.mozilla.org/mozilla-central/rev/3c61cc01a3b1 Gaia 9e0f6e30e5e28f88b4bbb4acb5e1fc99cdf7b7e7 BuildID 20130814040203 Version 26.0a1
Status: RESOLVED → REOPENED
Resolution: WORKSFORME → ---
Comment 9•11 years ago
|
||
It works now. Gecko http://hg.mozilla.org/mozilla-central/rev/a8daa428ccbc Gaia 58bb05efc83407428099a182244a1759ab84cd0b BuildID 20130815040204 Version 26.0a1 Don't know why but it works :D closing this
Status: REOPENED → RESOLVED
Closed: 11 years ago → 11 years ago
Resolution: --- → WORKSFORME
Updated•1 year ago
|
Product: Testing → Remote Protocol
You need to log in
before you can comment on or make changes to this bug.
Description
•