-
Notifications
You must be signed in to change notification settings - Fork 115
Open
Description
Hi there,
I am trying to create a block for bootsrap select2 element. Here is my code.
@Name("Select2")
public class Select2DropDownList extends HtmlElement {
@FindBy(className = "select2-choice")
Link selectLink;
@FindBy(xpath = "//*[@id='select2-drop']/div/input")
TextInput searchTextInput;
@FindBy(xpath = "//*[@id='select2-drop']/ul")
Ul selectResult;
public void selectOptionThatContains(String value) {
selectLink.click();
searchTextInput.clear();
searchTextInput.sendKeys(value);
selectResult.selectOptionThatContains(value);
}
}
The problem I am facing is that once searchTextInput.sendKeys(value) is being called it is taking sometime for result to appear. So how can I add wait after searchTextInput.sendKeys(value). Any example? Thank you in advance.
Metadata
Metadata
Assignees
Labels
No labels