https://github.com/testableapple/fastlane-plugin-try_adb_test
Give your Android tests a try 🚀
https://github.com/testableapple/fastlane-plugin-try_adb_test
Last synced: 7 months ago
JSON representation
Give your Android tests a try 🚀
- Host: GitHub
- URL: https://github.com/testableapple/fastlane-plugin-try_adb_test
- Owner: testableapple
- License: mit
- Created: 2021-04-09T12:13:28.000Z (about 5 years ago)
- Default Branch: main
- Last Pushed: 2023-09-11T15:20:16.000Z (over 2 years ago)
- Last Synced: 2025-10-13T12:54:17.705Z (7 months ago)
- Language: Ruby
- Homepage: https://alteral.github.io/fastlane_plugins
- Size: 9.77 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# try_adb_test plugin
[](https://rubygems.org/gems/fastlane-plugin-try_adb_test)
## About try_adb_test
The easiest way to retry your Android Instrumented Tests 🚀
Under the hood `try_adb_test` uses the stable version of the marvelous [`gojuno composer`](https://github.com/gojuno/composer) and allows you to customize your retry strategy.
| Option | Description | Default |
| ------- |------------ | ------- |
| apk | Either relative or absolute path to application apk that needs to be tested | |
| test_apk | Either relative or absolute path to apk with tests | |
| test_runner | Fully qualified name of test runner class you're using | Automatically parsed from test_apk's AndroidManifest |
| try_count | Number of times to try to get your tests green | 1 |
| shard | Either true or false to enable/disable [test sharding](https://developer.android.com/training/testing/junit-runner.html#sharding-tests) which statically shards tests between available devices/emulators | true |
| output_directory | Either relative or absolute path to directory for output: reports, files from devices and so on | fastlane/output |
| instrumentation_arguments | Key-value pairs to pass to Instrumentation Runner | Empty |
| verbose | Either true or false to enable/disable verbose output for Composer | false |
| devices | Connected devices/emulators that will be used to run tests against. Example: "emulator-5554 emulator-5556" | Empty, tests will run on all connected devices/emulators |
| device_pattern | Connected devices/emulators that will be used to run tests against. Example: "emulator.+" | Empty, tests will run on all connected devices/emulators |
| fail_if_no_tests | Either true or false to enable/disable error on empty test suite | true |
| install_timeout | Apk installation timeout in seconds. Applicable to both test Apk and Apk under test | 120 |
| extra_apks | Apks to be installed for utilities. What you would typically declare in gradle as androidTestUtil. Example: "path/to/apk/first.apk path/to/apk/second.apk" | Empty |
## Requirements
* JVM 1.8+
## Getting Started
To get started with `try_adb_test`, add it to your project by running:
```bash
$ fastlane add_plugin try_adb_test
```
## Usage
```ruby
try_adb_test(
try_count: 2,
test_runner: 'com.example.test.ExampleTestRunner',
test_apk: "app/build/outputs/apk/example-debug.apk",
apk: "app/build/outputs/apk/example-debug-androidTest.apk",
instrumentation_arguments: "package com.example",
device_pattern: 'emulator.+'
)
```