HTML Section :
<li tabindex="-1" role="option" unselectable="on" class="k-item k-state-focused" data-index="0" id="6609432f-2fd2-49c1-95df-6a330acecca0">admin</li>
Here the Xpath which I am trying :
driver.findelement(by.xpath("//li[text()=//li[. = 'admin']"));
But getting exception :
invalid selector: Unable to locate an element with the xpath expression //li[text()=//li[. = 'admin'] because of the following error:
SyntaxError: Failed to execute 'evaluate' on 'Document': The string '//li[text()=//li[. = 'admin']' is not a valid XPath expression.
Exact look at UI and HTML code :
That field is auto complete.ID is changing dynamic of that element so I can not use id here to find element.
