Class AnchorTester
java.lang.Object
com.vaadin.testbench.unit.ComponentTester<T>
com.vaadin.flow.component.html.testbench.HtmlComponentTester<T>
com.vaadin.flow.component.html.testbench.HtmlContainerTester<Anchor>
com.vaadin.flow.component.html.testbench.AnchorTester
-
Constructor Summary
Constructors -
Method Summary
Methods inherited from class com.vaadin.flow.component.html.testbench.HtmlContainerTester
getText
Methods inherited from class com.vaadin.flow.component.html.testbench.HtmlComponentTester
getTitle
Methods inherited from class com.vaadin.testbench.unit.ComponentTester
ensureComponentIsUsable, ensureComponentIsUsable, ensureVisible, ensureVisible, find, findAllByQuery, findByQuery, fireDomEvent, fireDomEvent, fireDomEvent, getComponent, getField, getField, getMethod, getMethod, isUsable, isUsable, notUsableReasons, notUsableReasons, roundTrip, setModal
-
Constructor Details
-
AnchorTester
Wrap given component for testing.- Parameters:
component
- target component
-
-
Method Details
-
getHref
Gets the URL that the anchor links to.- Returns:
- the href value, or
""
if no href has been set
-
click
Click the anchor for navigation if target is a registered route in the application.- Returns:
- navigated view
- Throws:
IllegalStateException
- if anchor href is not a String or not a route
-