Is there a known solution to perform Eval (Javascript execution) in Webdriver, Ruby bindings?
The equivalent of the following example in Java.
WebElement element = driver.findElement(By.id( "foo" ));
String name = (String) ((JavascriptExecutor) driver).executeScript(
"return arguments[0].tagName" , element)
The equivalent Ruby would be:
(to get the tag name you could also just call element.tag_name)