Skip to main content

DeviceAction

Description

This command allows you to execute device commands without having to specify key codes. You can use the deviceAction command to perform various actions on the device, actions that either require you to specify key code or require physical access to the device.

Parameters

NameValueDescription
ActionstringAction to execute

Usage

info

Replace <server> with the appropriate URL.

DeviceAction Command Usage

DesiredCapabilities dc = new DesiredCapabilities();
driver = new AndroidDriver(new URL("<server>"), dc);
seetest = new SeeTestClient(driver);
dc.setCapability(MobileCapabilityType.UDID, "<deviceid>");

...
...

//show the list of recent apps
seetest.deviceAction("Recent Apps");


List of Supported Actions

    • Home 

      - Click the Home button

    • Back 

      - Click the Back button

    • Power 

      - Click the Power key

    • Landscape 

      - Change orientation to landscape mode

    • Portrait 

      - Change orientation to portrait mode

    • Change Orientation 

      - Toggle orientation

    • Menu 

      - Click the Menu button

    • Unlock 

      - Unlock the device

    • Wake 

      - Wake the device

    • Paste 

      - Paste text from clipboard

    • Volume Up 

      - Click the Volume Up button

    • Volume Down 

      - Click the Volume Down button

    • Recent Apps 

       - Show recent apps