-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
74 lines (65 loc) · 2.02 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
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
language: android
jdk: oraclejdk7
# Use the Travis Container-Based Infrastructure
sudo: required
branches:
only:
- ci
cache:
directories:
- ${TRAVIS_BUILD_DIR}/gradle/caches/
- ${TRAVIS_BUILD_DIR}/gradle/wrapper/dists/
env:
global:
- ARTIFACTS_BUCKET=mobilization-artifacts
- ANDROID_API_LEVEL=23
- ANDROID_TARGET=android-23
- ANDROID_ABI=armeabi-v7a
- ANDROID_BUILD_TOOLS_VERSION=23.0.2
- ADB_INSTALL_TIMEOUT=20 # minutes (2 minutes by default)
addons:
artifacts:
s3_region: "us-west-1"
paths:
- $HOME/build/geaden/yandex-mobilization/app/build/reports
android:
components:
- platform-tools
- tools
- build-tools-$ANDROID_BUILD_TOOLS_VERSION
- android-$ANDROID_API_LEVEL
# Support library
- extra-android-support
# Latest artifacts in local repository
- extra-android-m2repository
# Specify at least one system image
- sys-img-armeabi-v7a-$ANDROID_TARGET
# Emulator Management: Create, Start and Wait
before_script:
- sudo service postgresql stop || true
- sudo service mysql stop || true
- sudo service memcached stop || true
- sudo service bootlogd stop || true
- sudo service elasticsearch stop || true
- sudo service mongodb stop || true
- sudo service neo4j stop || true
- sudo service cassandra stop || true
- sudo service riak stop || true
- sudo service rsync stop || true
- sudo service x11-common stop || true
- echo no | android create avd --force -n test -t $ANDROID_TARGET --abi $ANDROID_ABI
- emulator -avd test -no-skin -no-audio -no-window &
- android-wait-for-emulator
- adb devices
- adb shell input keyevent 82 &
script:
- ./gradlew clean checkAll -PdisablePreDex
after_failure:
# Make a screenshot
- adb shell screencap -p | sed 's/\r$//' > $HOME/build/geaden/yandex-mobilization/app/build/reports/screen.png
after_success:
# Upload results to coveralls
- ./gradlew coveralls
# Assemble release and upload current version
- ./gradlew assembleRelease
- ./gradlew upload -PbuildType=release