appium-roku-driver v0.1.1
π Appium Roku Driver
Appium Roku Driver is a test automation tool for Roku devices. Appium Roku Driver automates Roku applications, tested on real devices. Appium Roku Driver is part of the Appium test automation tool.
Installation
In order to use appium-roku-driver, we need to use appium version 1.16.0 or higher
npm i -g appium-roku-driverπ Usage
Import Roku Driver, set and create a session:
import { RokuDriver } from "appium-roku-driver";
let capabilities = {
app: "/Users/my-computer/3_Grid.zip",
deviceName: "Home",
appId: "dev",
platformName: "Roku",
contentId: "MV005011860000",
mediaType: "season",
ip: "10.10.1.1",
username: "rokuUser",
password: "rokuPass",
};
let driver = new RokuDriver();
await driver.createSession(capabilities);π Capabilities
Desired capabilities (caps) are a set of keys and values (i.e., a map or hash) sent to the Appium server to tell the server what kind of automation session weβre interested in starting up. There are various capabilities that can modify the behavior of the server during automation.
| Capability | Mandatory Fields | Description |
|---|---|---|
| app | β
| The absolute local path or remote http URL to a .zip1 |
| appId | β
| The appId is the identification for (channel / app) inside the OS |
| deviceName | β
| The kind of device to use1 |
| platformName | β
| Platform target will be automated1 |
| contentId | β
| Partner defined unique identifier for a specific piece of content2 |
| mediaType | β
| Parameter to give context to the type of contentID passed2 |
| ip | β
| Ip of the device on which the automation will be executed |
| username | β
| Username of device3 |
| password | β
| Password of device3 |
| noReset | π² | Don't reset app state before this session. See in the osicial documentation of Appium for more details4 |
| fullReset | π² | Perform a complete reset. See in the osicial documentation of Appium for more details4 |
| newCommandTimeout | π² | How long (in seconds) Appium will wait for a new command from the client before assuming the client quit and ending the session1 |
π Commands
Session
These commands are used for session administration.
createSession(capabilities);deleteSession();validateDesiredCaps(capabilities);Actions
These commands are used for actions administration.
getPageSource();getScreenshot();App Managment
These commands are used for application administration.
isAppInstalled(appId);appsInstalled();findAppInstalled(appId);isCheckVersion(app, appId);activateApp(appId, contentId, mediaType);removeApp(appId);terminateApp(appId);installApp(app, username, password);launchApp(appId, contentId, mediaType);closeApp();isStartedApp(appId);isAppActivated(appId);background(seconds);General
getDeviceTime();sendKey(key);pressHardwareKey(key);back();isKeyboardShown();hideKeyboard();5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago