I have an element onscreen that I am attempting to click, my test runner is telling me that SyntaxError: The expression is not a legal expression. I am trying to access an ' i ' tag on a button.
Here is my call to the driver:
driver.FindElement(By.XPath("//i[contains(@class, 'icon-magnifier']")).Click();
Here is my HTML
<button type="submit">
<i class="icon-magnifier"></i>
</button>
I would use the cssselector as my reference but when cut and paste from firebug it is ridiculously lengthy. Let me know what you would suggest to access this element.