0.2.18 • Published 5 years ago
monkey-runner v0.2.18
Script usage
monkey-runner
In order to run the test suites you need to use the following command from the root dir of your project.
Usage of the cli tool
monkey [command] [options]CLI command list
| command | description |
|---|---|
start | Command to start the TCP socket server. If ran with --debuggerUI flag it will run the monkey ui in a new terminal tab. |
assemble | Command to assemble the target application. If ran with flat -c it will clean the build folder and re-assemble the app. |
install | Command to install the assembled app to a running device. |
run | Command to start the monkey tests. The start command must be running on another terminal. |
emulator | Android - Command to start an android emulator if any are configured on the running device. |
NOTE!
- The following flags can be applied to all the commands but only used if the specific commands requires them.
- The commands work both for iOS and Android tests. To differentiate between mobile platforms please apply the the
--platformflag to the command.
Flags
The set of key arguments that are used by the monkey-runner script
| flags | description |
|---|---|
--help or -h | Optional - Help command. |
--screenshotPath or -s | Optional - Relative directory path for stored screenshots. Default /monkey-screenshots |
--tcpHost | Optional - The host in which the socket server is running. Default localhost, 127.0.0.1 |
--tcpPort | Optional - The port in which the socket server is running. Default 5678 |
--packageName | Optional - The package name of the target test application. If not provided the CLI will try to extract it from the project. |
--platform | Mobile platform to run the tests on, ios or android. Default android. |
--verbose or -v | Optional - Enable verbose mode. |
--cleanBuild or -c | Optional - Clean build flag. If passed, it will uninstall the old version, clean the build cached data and reassemble the app |
--headless | Optional - Flag to run the android emulator on headless mode |
--debuggerUI | Optional - Flag to run the debugger ui. |
Node
For issues using Iterm on mac please refer to this link