New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[stable12] Better handling of invisible elements in acceptance tests #8739

Merged
merged 2 commits into from Mar 9, 2018

Conversation

Projects
None yet
3 participants
@danxuliu
Member

danxuliu commented Mar 9, 2018

Backport of #8728

danxuliu added some commits Mar 8, 2018

Add automatic handling of MoveTargetOutOfBounds exceptions
MoveTargetOutOfBounds exceptions are sometimes thrown instead of
ElementNotVisible exceptions. This can happen when the Selenium2 driver
for Mink moves the cursor on an element using the "moveto" method of the
Webdriver session, for example, before clicking on an element. In that
case, if the element is not visible, "moveto" would throw a
MoveTargetOutOfBounds exception instead of an ElementNotVisible
exception, so those cases are handled like ElementNotVisible exceptions.

Note that MoveTargetOutOfBounds exceptions could be thrown too if the
element was visible but "out of reach"; there is no problem in handling
those cases as if the element was not visible, as the exception will be
thrown again anyway once it is verified that the element is indeed
visible.

Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
Add automatic handling of NoSuchElement exceptions
NoSuchElement exceptions are sometimes thrown instead of
StaleElementReference exceptions. This can happen when the Selenium2
driver for Mink performs an action on an element through the WebDriver
session instead of directly through the WebDriver element. In that case,
if the element with the given ID does not exist, a NoSuchElement
exception would be thrown instead of a StaleElementReference exception,
so those cases are handled like StaleElementReference exceptions.

Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>

@danxuliu danxuliu added this to the Nextcloud 12.0.6 milestone Mar 9, 2018

@danxuliu danxuliu requested review from rullzer, MorrisJobke and skjnldsv Mar 9, 2018

@rullzer

rullzer approved these changes Mar 9, 2018

@rullzer rullzer merged commit 6bd630d into stable12 Mar 9, 2018

1 of 2 checks passed

continuous-integration/drone/pr the build failed
Details
continuous-integration/drone/push the build was successful
Details

@rullzer rullzer deleted the stable12-8728-better-handling-of-invisible-elements-in-acceptance-tests branch Mar 9, 2018

@MorrisJobke MorrisJobke referenced this pull request Mar 9, 2018

Merged

12.0.6 RC 1 #8750

2 of 2 tasks complete
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment