kgress / scaffold

A Java based Selenium WebDriver abstraction
MIT License
4 stars 7 forks source link

Add click retries to AbstractClickable #90

Open kgress-heb opened 3 years ago

kgress-heb commented 3 years ago

Summary

Currently, scaffold does not handle re clicking of elements if a click fails. A click retry can be helpful if working with a webpage that has a slow state change or slow javascript.

We could achieve click retry logic with a test setting similar to how we're setting explicit waits. By enable click retry, we could write the logic for the click retry as a generic on AbstractClickable. Therefore, any time a calling class performs the click, the retry will be checked and executed.

I think the following would be a good set of parameters for the retry:

A/C

kgress commented 2 years ago

I think we could also add a Desired Capability for setting click retries, in addition to also providing how many retries the user would like.