Selenium IDE-Automating Select2 Selection Window

I am trying to automate select2 select box in Selenium IDE. I got it to open, and also typed in the search keyword I'm looking for. Despite the fact that I have code to display the results, it does not work. The problem is that I guess that the characters are typed too fast, so the results are not displayed for the search box. I am sure that I am mistaken somewhere because I am new to the Selenium IDE. Any help is appreciated.

mouseDown css=.select2-choice > div > b type css=input.select2-input.select2-focused Chris waitForVisible css=.select2-results mouseUp css=.select2-result-label:contains('Chris') 
+8
ide selenium jquery-select2
source share
1 answer

I had to deal with this, the sites I'm testing use select2 and select3. What I found to work in both situations would be the following:

 clickAt | css=.select2-choice > div > b | sendKeys | css=input.select2-input.select2-focused | Chris click | css=.select2-result-label:contains('Chris') 

With these types of dropdowns and Angular, I found that sendKeys works better than type or typeKeys.

Klendathu

+6
source share

All Articles