background image
<< Java Test example | How Selenium works >>

A few Selenese commands

<< Java Test example | How Selenium works >>
A few Selenese commands
click
getHtmlSource
isVisible
close
getTitle
keyPress
createCookie
getValue
mouseOver
dragdrop
goBack
open
fireEvent
isElementPresent
refresh
getEval
isTextPresent
type
Element locators
·
ID: id=foo
·
Name: name=foo
·
First ID, then name: identifier=foo
·
DOM: document.forms[`myform'].myDropdown
·
XPath: xpath=//table[@id='table1']//tr[4]/td[2]
·
Link Text: link=sometext
·
CSS Selector: css=a[href="#id3"]
·
Sensible defaults, e.g. xpath if starts with //
selenium
.click(
"btnG
");