-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.travis.yml
53 lines (46 loc) · 1.92 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
language: android
jdk: oraclejdk8
sudo: false
env:
global:
- ANDROID_API=android-24 # API-version für den Emulator (android-XX)
- ANDROID_ABI=arm64-v8a # das Image für den Emulator (armv7/armv8/x86/x86_64)
- ANDROID_BUILD_TOOLS=26.0.2 # die Version der build-tools (am besten aktuellste version)
- ADB_INSTALL_TIMEOUT=5 # Timeout für die Installation der App im Emulator
android:
components:
#- tools # SDK-update
- platform-tools # platform-tools update
- tools # SDK-update (absichtlich doppelt)
- build-tools-$ANDROID_BUILD_TOOLS # build-tools, welche die App verwendet
- android-$ANDROID_API # Android SDK um die App zu kompilieren
- extra-android-m2repository # evt. benötigte m2-repositories
- $ANDROID_ABI-$ANDROID_API
#system-images;android-19;default;armeabi-v7a
# Emulator Management: Create, Start and Wait
before_script:
- echo yes | $ANDROID_HOME/tools/bin/sdkmanager --update
- echo yes | $ANDROID_HOME/tools/bin/sdkmanager --licenses
- echo yes | $ANDROID_HOME/tools/bin/sdkmanager "system-images;$ANDROID_API;default;$ANDROID_ABI"
- echo no | $ANDROID_HOME/tools/bin/avdmanager create avd --force -n test -k "system-images;$ANDROID_API;default;$ANDROID_ABI"
- $ANDROID_HOME/tools/emulator -avd test -no-audio -no-window &
- android-wait-for-emulator
- adb shell input keyevent 82 &
script:
- ./gradlew test
- sonar-scanner
addons:
sonarcloud:
organization: "mamen-github" # the key of the org you chose at step #3
token:
secure: $SONAR_TOKEN
before_cache:
- rm -f $HOME/.gradle/caches/modules-2/modules-2.lock
- rm -fr $HOME/.gradle/caches/*/plugin-resolution/
cache:
directories:
- $HOME/.gradle/caches/
- $HOME/.gradle/wrapper/
- $HOME/.android/build-cache
notifications:
email: false