@Test public void shouldAllowOptionsToBeDeselectedByReturnedValue() { WebElement selectElement = driver.findElement(By.name("multi")); Select select = new Select(selectElement); select.deselectByValue("eggs"); List<WebElement> returnedOptions = select.getAllSelectedOptions(); assertEquals(1, returnedOptions.size()); }
public void deselectByValue() { select.deselectByValue(getData()); }