This repository was archived by the owner on Mar 19, 2021. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy path.travis.yml
55 lines (46 loc) · 1.42 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
53
54
55
language: android
dist: trusty
notifications:
email: false
jdk:
- oraclejdk8
env:
global:
- ADB_INSTALL_TIMEOUT=10
- ANDROID_API_LEVEL=28
- ANDROID_BUILD_TOOLS_VERSION=29.0.2
- EMU_NAME=test
- EMU_API_LEVEL=23
- EMU_ABI=armeabi-v7a
# - EMU_ABI=x86
android:
components:
- tools
- platform-tools
- build-tools-$ANDROID_BUILD_TOOLS_VERSION
- android-$ANDROID_API_LEVEL
- android-$EMU_API_LEVEL
- extra-android-support
- sys-img-$EMU_ABI-google_apis-$EMU_API_LEVEL
licenses:
- 'android-sdk-license-.+'
before_install:
- chmod +x gradlew
# https://github.com/travis-ci/travis-ci/issues/8874#issuecomment-350350607
- yes | sdkmanager "platforms;android-$ANDROID_API_LEVEL"
- yes | sdkmanager "platforms;android-$EMU_API_LEVEL"
before_script:
- ./gradlew build jacocoTestReport assembleAndroidTest
- echo no | android create avd --force -n $EMU_NAME -t android-$EMU_API_LEVEL --abi google_apis/$EMU_ABI
# Do not remove '-no-window' from the next instruction because "Waiting for emulator to start" will return super fast
# and then, inside 'script:', we'll receive an error because apparently there's no device ready
- emulator -avd $EMU_NAME -no-window &
- android-wait-for-emulator
- adb shell input keyevent 82 &
script:
- ./gradlew connectedCheck --stacktrace
after_success:
- bash <(curl -s https://codecov.io/bash)
branches:
only:
- master