-
Notifications
You must be signed in to change notification settings - Fork 1
/
.travis.yml
73 lines (60 loc) · 1.72 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
#
# Configuration
#
sudo: required
dist: trusty
notifications:
email: true
addons:
apt:
sources:
- ubuntu-toolchain-r-test
- google-chrome
packages:
- google-chrome-stable
- lib32stdc++6
- lib32z1
branches:
only:
- master
- rc0
#
# Build Lifecycle:
#
before_install:
- nvm install node
- nvm use node
- npm install -g cordova ionic
- ionic state clear
install: npm install
before_script:
- export DISPLAY=:99.0
- sh -e /etc/init.d/xvfb start
script:
- ng test --watch=false # unit tests
# - npm run build # ionic build
# Serve with python as ionic serve needs interaction
# - cd www && python -m SimpleHTTPServer 8100 >> python_serve.log 2>&1 &
# - npm run e2e # run e2e tests against ionic
after_failure:
- cat /home/travis/build/lathonez/clicker/python_serve.log
- cat /home/travis/build/lathonez/clicker/ionic_serve.log
after_success:
# Send coverage info off to cloud ppl
- cat coverage/lcov.info | ./node_modules/.bin/codecov
before_deploy:
# start install android
- wget http://dl.google.com/android/android-sdk_r24.2-linux.tgz
- tar -xzvf android-sdk_r24.2-linux.tgz
- echo "y" | ./android-sdk-linux/tools/android update sdk --no-ui --filter android-23,build-tools-23.0.1
- export ANDROID_HOME=${PWD}/android-sdk-linux
# end install android
- ionic state restore
- ionic platform add android
- ionic build android
# `ionic build android` wraps `cordova build android`, which gives a legit exit code if it fails. Ionic does not; test apk exists.
- ls ./platforms/android/build/outputs/apk/android*.apk
deploy:
provider: script
script: .travis/deploy.sh
skip_cleanup: true