See the following mehtods:
public <T extends net.serenitybdd.core.pages.WebElementFacade> T find(List<By> selectors) {
T element = null;
for (By selector : selectors) {
if (element == null) {
element = element(selector);
} else {
element = element.find(selector);
}
}
return element;
}
public <T extends net.serenitybdd.core.pages.WebElementFacade> T element(By bySelector) {
return net.serenitybdd.core.pages.WebElementFacadeImpl.wrapWebElement(driver,
bySelector,
getImplicitWaitTimeout().in(MILLISECONDS),
getWaitForTimeout().in(MILLISECONDS),
bySelector.toString());
}
Looking at the method find(List<By> selelectors) one can see that in the if branch of the if clause element(selector) is being called. This result in an instance of WebElementFacadeImpl without checking if the element is present on the page (not visible, just present) or not. Though, in the else branch element.find(selector) is called, which causes a NoSuchElementException to be thrown if the element is not present.
In my opinion this behaviour is a bit inconsistent. In older version there has always beent trigged a NoSuchElementException whenever the element could not be located on page.