forked from algolia/algoliasearch-client-android
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
52 lines (50 loc) · 1.78 KB
/
.travis.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
branches:
only:
- master
sudo: required
dist: precise # require Precise infrastructure: fully virtualized, 7.5GB RAM
language: android
jdk:
- oraclejdk8
env:
global:
- secure: DENCjlvzW54U9QH7mWO3LJVLYEiX0Mj9U44QoGQcienflSDlVN1UhAiT7xnCKwWT38B37CzeQlHc541z78vAj+YPzPbebowFW0aiq/LNdFMigsT1j3gLpqrICjylG08i1Ho95FLCOaJSQWZJ5nSd3OceWLLxCYUXtS9E3BuMHGg=
- secure: HBdvSvplPEJWEu7aij7cA+ZiQt2qmb9+Q8WsUGOJJ1uYIOt/MVHSo0bYYLfk90eFlnJecN+oBi92LCM9PUT3mKIHm9apRsK9os+W/6wIezD+rKVYPfOLZ4uINaFRDjXUJqKB46fzVR54vc4N2QO0+spn7Sv7sXaytYEPwrO6tmo=
- ANDROID_ABI=armeabi-v7a
matrix:
- ANDROID_TARGET=android-16
- ANDROID_TARGET=android-17
- ANDROID_TARGET=android-19
- ANDROID_TARGET=android-22
- ANDROID_TARGET=android-24
matrix:
fast_finish: true
android:
components:
- tools
- platform-tools
- tools # Fix SDK Tools https://github.com/travis-ci/travis-ci/issues/6122
- build-tools-24.0.3
- android-24 # target SDK version
- $ANDROID_TARGET
- extra-android-support
- extra-android-m2repository
- sys-img-armeabi-v7a-$ANDROID_TARGET
cache:
directories:
- $HOME/.gradle/caches/
- $HOME/.gradle/daemon
- $HOME/.gradle/native
- $HOME/.gradle/wrapper
before_script:
# Avoid useless reupload of cache after every build, see https://docs.travis-ci.com/user/languages/android
- rm -f $HOME/.gradle/caches/modules-2/modules-2.lock
# Create Android Virtual Device with current config, saying no to custom build
- echo no | android create avd --force -n test -t $ANDROID_TARGET --abi $ANDROID_ABI
# Run emulator and wait until it is ready, then send KEYCODE_MENU to unlock the phone
- emulator -avd test -no-skin -no-window &
- android-wait-for-emulator
- adb shell input keyevent 82 &
script:
- set -o pipefail
- travis_wait bash run_test.sh