4 Answers
4

You can try avoid relative xpaths if those can be avoided. In your html, the select element has a unique identifier, the id, which can be used.

You can try the below:

Select sel = new Select(driver.findElementById("CardProvider"));
sel.selectByVisibleText - there are options here to select by index, visible text and value - choose any which you think would be stable.