Skip to content

Instantly share code, notes, and snippets.

@aoudiamoncef
Last active November 7, 2017 14:04
Show Gist options
  • Save aoudiamoncef/a78bf59c1d1789dae8ae75e2289a47ff to your computer and use it in GitHub Desktop.
Save aoudiamoncef/a78bf59c1d1789dae8ae75e2289a47ff to your computer and use it in GitHub Desktop.
Android continuous integration using Travis CI (build, unit tests and connected tests using AVD)
# For more informations, please read official documentation -> https://docs.travis-ci.com/user/languages/android/
sudo: false
language: android
jdk: oraclejdk8
before_cache:
- rm -f $HOME/.gradle/caches/modules-2/modules-2.lock
- rm -rf $HOME/.gradle/caches/*/plugin-resolution/
cache:
directories:
- $HOME/.gradle/caches/
- $HOME/.gradle/wrapper/
- $HOME/.android/build-cache
env:
global:
- ANDROID_API_LEVEL=26
- ANDROID_BUILD_TOOLS=26.0.2
android:
components:
- tools
- tools # Running this twice get's the latest build tools (https://github.com/codepath/android_guides/wiki/Setting-up-Travis-CI)
- platform-tools
- android-$ANDROID_API_LEVEL
- build-tools-$ANDROID_BUILD_TOOLS
script:
- ./gradlew clean test build
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment