Annotation Type Root
This annotation marks the WebElement field where should be injected the root of the given fragment,
given by @FindBy annotation on a injection point.
public class AutocompletionInput {
@Root
WebElement input;
public void typeText(String text) {
input.typeText(text);
}
public void select(String suggestion) {
...
}
}
@RunWith(Arquillian.class)
public class Test {
@FindBy(css = ".autocompletion")
AutocompletionInput autocomplete;
@Test
public void test() {
autocomplete.typeText("Arq");
autocomplete.select("Arquillian");
}
}
- Author:
- Juraj Huska