I'm trying to test a page that has an input but really its a drop down list. The user enters text and then a dropdown appears based on what the user inputted. They are groups that are in the database. If I look for these elements before typing anything they dont exist but once I start typing they do exist. The problem is I cant just type the whole name and then press enter or return because an option has to be selected from the list. I can press arrow down to get the focus on the item from the list but then if I say enter it doesnt select, it sends that enter to the original element and nothing gets selected. I can find the select element:
var ddList = driver.FindElement(By.CssSelector(".ui-autocomplete-input"));
ddList.SendKeys("Admins");
This is the first time the list appears in the html. It looks like this:
<li class="ui-menu-item" role="presentation">