The iPhone Convenience API is only available for the Squish for iPhone editions.
The Squish documentation uses the term widget when referring to GUI objects. Mac OS X developers may be more familiar with the term view for this concept.
Here are some quick links to the iPhone Convenience API's functions:
clickObject(objectOrName, x, y
This function performs a tap on the specified
By default the
objectOrName widget is clicked in
the middle, but this can be overridden by passing
doubleClick(objectOrName, x, y
This function performs a double tap on the specified
By default the
objectOrName widget is
double-tapped in the middle, but this can be overridden
by passing object-relative coordinates,
This function installs a global event handler. The script function
handlerFunctionName (which must be passed
as a string, not as a function reference), will be called when an event
eventName type occurs.
eventName can be the name of any of the
following event types:
AlertOpened event occurs, the function
handlerFunctionName is called. The
function is passed one argument—the alert object that was opened
(i.e. an object of type UIAlertView).
For examples see How to Use Event Handlers (Section 14.8).
|The AUT Must be Running|
This function selects an item in the specified
object (a picker widget is a spinning-wheel control that allows users to
choose things such as dates).
row is the 0-based index position of the row
that should be selected. The
componentIndex is the
0-based index position of the component (or column) that contains the
This function performs a dragging gesture (also known as a panning
gesture). The gesture starts at position
y relative to the
objectOrName widget and continues for
dx pixels to the righ (left if the amount is
dy pixels down (up if the
amount is negative).
This function types the specified
text (as if the
user had entered the text using the on-screen keyboard) into the
objectOrName editable widget. If the text is
surrounded by angle brackets (<>), it is interpreted as a special
key, e.g "<Return>". The input is case-sensitive, so
type(object, "R") is different from
Currently the following special keys are supported: