New to fastlane? Click here to open the installation & setup instructions first
1) Install the latest Xcode command line tools
2) Install fastlane
# Using RubyGems sudo gem install fastlane -NV # Alternatively using Homebrew brew install fastlane
3) Navigate to your project and run
Running Android tests using fastlane
To run your unit tests using fastlane, add the following to your
lane :tests do gradle(task: "test") end
"test" with the gradle task name for running unit tests of your app.
Additionally you can specify more options for building and testing your app, check out the list of all available parameters
To use the newly created lane, just run
Setting up fastlane to run on CI
To run Android tests using fastlane on a Continuous Integration service, check out the Continuous Integration docs.
Since fastlane stores all configuration in simple configuration files, and runs via the command line, it supports every kind of CI system.
We also prepared some docs to help you get started with some of the popular CI systems.
If your CI system isn't listed here, no problem, fastlane runs on any CI. To trigger fastlane, just add the command you would usually run from your terminal:
Posting build results
If you want to post test results on Slack, Hipchat, or other team chat client, check out the available fastlane actions.
To post a message when fastlane encounters a test or build failure, add the following to your
error do |ex| hipchat(message: "Tests have failed!", channel: "Room or @username", success: false) end
The above example uses Hipchat, but fastlane supports many other services out there.