How do I select in Selenium?
You can leverage the Selenium ‘Select’ class present in Selenium WebDriver to select and deselect from the dropdown option. You can initialize the Select type objects when you pass the dropdown webElement as a constructor parameter.
WebElement testDropDown = driver.findElement(By.id(“testingDropdown”));
Select dropdown = new Select(testDropDown);