Closed
Bug 1192751
Opened 9 years ago
Closed 9 years ago
[v2.5][Gaia::UI Tests]test_sms.py: "NoSuchElementException: NoSuchElementException: Unable to locate element: thread-messages"
Categories
(Firefox OS Graveyard :: Gaia::UI Tests, defect)
Tracking
(Not tracked)
RESOLVED
FIXED
People
(Reporter: liuke, Assigned: martijn.martijn)
References
Details
Attachments
(1 file)
[Description] test_sms.py fails [Steps to Reproduce] test_sms.py [Reproduction Frequency] Always, 5/5 [Reproducible manually] NO Traceback (most recent call last): File "/var/lib/jenkins/workspace/B2G.master.TaskCluster.FlameKK.gaiatest.smoketest/tests/python/gaia-ui-tests/.env/local/lib/python2.7/site-packages/marionette_client-0.16-py2.7.egg/marionette/marionette_test.py", line 296, in run testMethod() File "/var/lib/jenkins/workspace/B2G.master.TaskCluster.FlameKK.gaiatest.smoketest/tests/python/gaia-ui-tests/gaiatest/tests/functional/messages/test_sms.py", line 25, in test_sms_send new_message = self.messages.tap_create_new_message() File "/var/lib/jenkins/workspace/B2G.master.TaskCluster.FlameKK.gaiatest.smoketest/tests/python/gaia-ui-tests/gaiatest/apps/messages/app.py", line 31, in tap_create_new_message return NewMessage(self.marionette) File "/var/lib/jenkins/workspace/B2G.master.TaskCluster.FlameKK.gaiatest.smoketest/tests/python/gaia-ui-tests/gaiatest/apps/messages/regions/new_message.py", line 32, in __init__ section = self.marionette.find_element(*self._thread_messages_locator) File "/var/lib/jenkins/workspace/B2G.master.TaskCluster.FlameKK.gaiatest.smoketest/tests/python/gaia-ui-tests/.env/local/lib/python2.7/site-packages/marionette_driver-0.9-py2.7.egg/marionette_driver/marionette.py", line 1589, in find_element response = self._send_message('findElement', 'value', **kwargs) File "/var/lib/jenkins/workspace/B2G.master.TaskCluster.FlameKK.gaiatest.smoketest/tests/python/gaia-ui-tests/.env/local/lib/python2.7/site-packages/marionette_driver-0.9-py2.7.egg/marionette_driver/decorators.py", line 36, in _ return func(*args, **kwargs) File "/var/lib/jenkins/workspace/B2G.master.TaskCluster.FlameKK.gaiatest.smoketest/tests/python/gaia-ui-tests/.env/local/lib/python2.7/site-packages/marionette_driver-0.9-py2.7.egg/marionette_driver/marionette.py", line 715, in _send_message self._handle_error(response) File "/var/lib/jenkins/workspace/B2G.master.TaskCluster.FlameKK.gaiatest.smoketest/tests/python/gaia-ui-tests/.env/local/lib/python2.7/site-packages/marionette_driver-0.9-py2.7.egg/marionette_driver/marionette.py", line 751, in _handle_error raise errors.lookup(status)(message, stacktrace=stacktrace) NoSuchElementException: NoSuchElementException: Unable to locate element: thread-messages [Build info] Build ID 20150809150206 Gaia Revision 3e5271663e7ef26290c29a45d2e42c0d3c20fe04 Gaia Date 2015-08-08 21:13:59 Gecko Revision https://hg.mozilla.org/mozilla-central/rev/fd69d51a4068 Gecko Version 42.0a1 Device Name flame Firmware(Release) 4.4.2 Firmware(Incremental) eng.cltbld.20150809.182413 Firmware Date Sun Aug 9 18:24:24 EDT 2015 Firmware Version v18D v4 Bootloader L1TC000118D0 [Attachments] http://mozilla-twqa.github.io/Gaiatest-Reports/2015/08/20150808011057-v2.5-FlameKK/smoketest.html
Assignee | ||
Comment 1•9 years ago
|
||
Apparently, this was changed in bug 1162030.
Assignee: nobody → martijn.martijn
Blocks: 1162030
Comment 2•9 years ago
|
||
Assignee | ||
Comment 3•9 years ago
|
||
Comment on attachment 8646331 [details] [gaia] mwargers:1192751 > mozilla-b2g:master Using the same Wait as in tap_message: http://mxr.mozilla.org/gaia/source/tests/python/gaia-ui-tests/gaiatest/apps/messages/regions/new_message.py#45 I think it's better to not rely on too many locators, if possible and I think this is a case where we could just use this locator to be sure the app is ready to use.
Attachment #8646331 -
Flags: review?(npark)
Attachment #8646331 -
Flags: review?(jlorenzo)
Comment 4•9 years ago
|
||
Comment on attachment 8646331 [details]
[gaia] mwargers:1192751 > mozilla-b2g:master
Agree, we should only check what's needed. LGTM
Attachment #8646331 -
Flags: review?(npark) → review+
Comment on attachment 8646331 [details]
[gaia] mwargers:1192751 > mozilla-b2g:master
Agreed on removing the locator, if it's superfluous. However, we need to wait for the transition to be over, as it's still in the product.
The main reason is: Marionette retrieves element positions to perform the tap and such. If we don't wait for the transition to be over, Marionette sometimes gets a position of a moving element, and the next millisecond, Marionette can't tap it.
Attachment #8646331 -
Flags: review?(jlorenzo)
Assignee | ||
Comment 6•9 years ago
|
||
Comment on attachment 8646331 [details]
[gaia] mwargers:1192751 > mozilla-b2g:master
Ok, in that case, in that case we still need to have this check for this section element. I replaced location with rect, because location is deprecated.
Also, I added a .is_displayed() check, because rect['x] is 0 when the element is not displayed at all.
Attachment #8646331 -
Flags: review?(jlorenzo)
Comment on attachment 8646331 [details]
[gaia] mwargers:1192751 > mozilla-b2g:master
I didn't know location was planned to be removed. Thanks for the info.
And the test looks good to me :)
Attachment #8646331 -
Flags: review?(jlorenzo) → review+
Assignee | ||
Comment 8•9 years ago
|
||
Merged: https://github.com/mozilla-b2g/gaia/commit/8f5bbbf58e6b026f23316874ff861bc2500bdab2
Status: NEW → RESOLVED
Closed: 9 years ago
Resolution: --- → FIXED
You need to log in
before you can comment on or make changes to this bug.
Description
•