Reputation: 11
I could not select Multi-Value Select Boxes (http://select2.github.io/select2/)
I try:
cy.get('s2id_e9').click()
cy.get('ul li:first').contains('California').select()
but it does not work.
How can I select these options? Hope someone can help?
Upvotes: 1
Views: 4153
Reputation: 267
This worked for multi select dropdowns
cy.get('[name="Optionwithcheck[]"]').select(['Option 2','Option 3'])
Upvotes: 1
Reputation: 816
cy.get('#s2id_e9 ul.select2-choices').click()
cy.contains('.select2-result-label', 'California').click()
Upvotes: 1