In the following code snippet, an AngularJS based dropdown menu is implemented:
<select _ngcontent-c1="" class="form-control ng-pristine ng-valid ng-touched">
After opening the list, I attempted to select a variable from this list using the code below:
driver.findElement(By.xpath("//*[contains(text(), '"valuetobeselected"')]")).click();