You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is there a reason that TypifiedElement doesn't implement WebElement?
The main reason for asking is to simplify use of ExpectedConditions, especially when using a list of them e.g. List<CheckBox> checkboxes.
I'd like to do: wait.until(ExpectedConditions.visibilityOfAllElements(checkboxes)) but because visibilityOfAllElements only accepts List<WebElement> this doesn't work, equally for visibilityOf having to add .getWrappedElement() isn't ideal.
Also, as the PageFactory replaces them with lazy proxies if trying to convert that into a list of WebElements to wait for, I'm not sure the following would work?
I've created a PR which solved the visibilityOf(checkBox) problem from an interface point of view.
However Lists are more complex. When doing
// wait has timeout of 10s
wait.until(visibilityOfAllElements(checkBoxes.stream()
.map(te -> (WebElement) te)
// same behaviour with
//.map(TypifiedElement::getWrappedElement)
.collect(toList())))
It fails after 5s (the implicit wait as mentioned in #111) - is there a way, without using the @Timeout everywhere, to utilise the explicit wait for lists?
Is there a reason that
TypifiedElement
doesn't implementWebElement
?The main reason for asking is to simplify use of
ExpectedConditions
, especially when using a list of them e.g.List<CheckBox> checkboxes
.I'd like to do:
wait.until(ExpectedConditions.visibilityOfAllElements(checkboxes))
but because visibilityOfAllElements only acceptsList<WebElement>
this doesn't work, equally forvisibilityOf
having to add.getWrappedElement()
isn't ideal.Also, as the PageFactory replaces them with lazy proxies if trying to convert that into a list of WebElements to wait for, I'm not sure the following would work?
Or is there something I've missed?
The text was updated successfully, but these errors were encountered: