https://github.com/pink-room/fastlane-plugin-run_tests_firebase_testlab
Runs Android tests in Firebase Test Lab 🚀
https://github.com/pink-room/fastlane-plugin-run_tests_firebase_testlab
android fastlane fastlane-plugin fastlane-plugins firebase firebase-test-lab instrumentation-tests testing tests-firebase-testlab
Last synced: about 1 year ago
JSON representation
Runs Android tests in Firebase Test Lab 🚀
- Host: GitHub
- URL: https://github.com/pink-room/fastlane-plugin-run_tests_firebase_testlab
- Owner: pink-room
- License: mit
- Created: 2018-01-30T11:43:52.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2019-08-17T17:04:06.000Z (almost 7 years ago)
- Last Synced: 2025-04-14T20:56:07.278Z (about 1 year ago)
- Topics: android, fastlane, fastlane-plugin, fastlane-plugins, firebase, firebase-test-lab, instrumentation-tests, testing, tests-firebase-testlab
- Language: Ruby
- Homepage:
- Size: 49.8 KB
- Stars: 48
- Watchers: 5
- Forks: 10
- Open Issues: 4
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# run_tests_firebase_testlab plugin
[](https://rubygems.org/gems/fastlane-plugin-run_tests_firebase_testlab)
[](https://travis-ci.org/pink-room/fastlane-plugin-run_tests_firebase_testlab)
[](https://badge.fury.io/rb/fastlane-plugin-run_tests_firebase_testlab)
Please, read [this](https://medium.com/pink-room-club/android-continuous-integration-using-fastlane-and-circleci-2-0-part-i-7204e2e7b8b) blog post if you want to know better how to use this plugin.
## Getting Started
This project is a [_fastlane_](https://github.com/fastlane/fastlane) plugin. To get started with `fastlane-plugin-run_tests_firebase_testlab`, add it to your project by running:
```bash
fastlane add_plugin run_tests_firebase_testlab
```
## About run_tests_firebase_testlab
* Authenticates with Google Cloud.
* Runs Android tests in Firebase Test Lab.
* Fetches the results to a local directory.
* Deletes the results from firebase bucket if wanted.
## Example
Check out the [example `Fastfile`](fastlane/Fastfile) to see how to use this plugin.
### Simple usage
```
run_tests_firebase_testlab(
project_id: "your-firebase-project-id",
devices: [
{
model: "Nexus6P",
version: "27"
}
]);
```
### Parameters
Parameter
Description
Optional
Default
project_id
Your Firebase project id
No
-
devices
A list of devices to test the App on
No
-
device[model]
A device model on which the tests will run
No
-
device[version]
The Android api version of the device
No
-
device[locale]
The locale to test against
Yes
en_US
device[orientation]
The orientation of the device
Yes
portrait
app_apk
The path for your app apk
Yes
app/build/outputs/apk/debug/
app-debug.apk
android_test_apk
The path for your android test apk
Yes
app/build/outputs/apk/androidTest/
debug/app-debug-androidTest.apk
timeout
The max time this test execution can run before it is cancelled
Yes
30m
output_dir
The directory to save the output results
Yes
firebase
bucket_url
The bucket url where the test results were stored
Yes
Parsed automatically from tests output
delete_firebase_files
A flag to control if the firebase files should be deleted from the bucket or not
Yes
false
extra_options
Extra options that you need to pass to the gcloud command
Yes
empty string
gcloud_service_key_file
File path containing the gcloud auth key
Yes
Created from GCLOUD_SERVICE_KEY environment variable
download_results_from_firebase
A flag to control if the firebase files should be downloaded from the bucket or not
Yes
true
## Run tests for this plugin
To run both the tests, and code style validation, run
```
rake
```
To automatically fix many of the styling issues, use
```
rubocop -a
```
## Issues and Feedback
For any other issues and feedback about this plugin, please submit it to this repository.
## Troubleshooting
If you have trouble using plugins, check out the [Plugins Troubleshooting](https://docs.fastlane.tools/plugins/plugins-troubleshooting/) guide.
## Using _fastlane_ Plugins
For more information about how the `fastlane` plugin system works, check out the [Plugins documentation](https://docs.fastlane.tools/plugins/create-plugin/).
## About _fastlane_
_fastlane_ is the easiest way to automate beta deployments and releases for your iOS and Android apps. To learn more, check out [fastlane.tools](https://fastlane.tools).