-
Notifications
You must be signed in to change notification settings - Fork 24
/
Copy path.travis.yml
108 lines (105 loc) · 3.69 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
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
env:
global:
- ANDROID_PACKAGE='app-debug.apk'
- ANDROID_PACKAGE_FOLDER=$TRAVIS_BUILD_DIR/demo/platforms/android/app/build/outputs/apk/debug
- ANDROID_SAUCE_STORAGE="https://saucelabs.com/rest/v1/storage/$SAUCE_USER/$ANDROID_PACKAGE?overwrite=true"
- IOS_PACKAGE='demo.zip'
- IOS_PACKAGE_FOLDER=$TRAVIS_BUILD_DIR/demo/platforms/ios/build/emulator
- IOS_SAUCE_STORAGE="https://saucelabs.com/rest/v1/storage/$SAUCE_USER/$IOS_PACKAGE?overwrite=true"
matrix:
include:
- stage: "Lint"
language: node_js
os: linux
node_js: "8"
script: cd src && npm run ci.tslint && cd ../demo && npm run ci.tslint
- stage: "WebPack, Build and Test"
os: osx
env:
- WebPack="iOS"
osx_image: xcode10
language: node_js
node_js: "8"
jdk: oraclejdk8
before_install: pip install six
script: cd demo && npm run build.ci.iosOnly && npm i && tns build ios --bundle --env.uglify
- language: android
os: linux
env:
- WebPack="Android"
jdk: oraclejdk8
before_install: nvm install 8
script: cd demo && npm run build.ci.plugin && npm i && tns build android --bundle --env.uglify --env.snapshot
- language: android
env:
- BuildAndroid="28"
os: linux
jdk: oraclejdk8
before_install: nvm install stable
script:
- cd src && npm run clean.ci && npm run tsc && cd ../demo && npm run clean && tns build android
- "curl -u $SAUCE_USER:$SAUCE_KEY -X POST -H 'Content-Type: application/octet-stream' $ANDROID_SAUCE_STORAGE --data-binary @$ANDROID_PACKAGE_FOLDER/$ANDROID_PACKAGE.apk"
- os: osx
env:
- BuildiOS="12"
- Xcode="10.0"
osx_image: xcode10
language: node_js
node_js: "8"
jdk: oraclejdk8
before_install: pip install six
script:
- cd src && npm run clean.ci && npm run tsc && cd ../demo && npm run clean && tns build ios
- cd $IOS_PACKAGE_FOLDER && zip -r $IOS_PACKAGE demo.app
- "curl -u $SAUCE_USER:$SAUCE_KEY -X POST -H 'Content-Type: application/octet-stream' $IOS_SAUCE_STORAGE --data-binary @$IOS_PACKAGE_FOLDER/$IOS_PACKAGE"
- os: linux
language: android
dist: precise
sudo: required
jdk: oraclejdk8
before_script:
- echo no | android create avd --force -n test -t android-21 -b armeabi-v7a
- emulator -avd test -no-audio -no-window &
- android-wait-for-emulator
before_install:
- nvm install 8
script: cd src && npm run test.ci.android
- os: osx
language: node_js
node_js: "8"
jdk: oraclejdk8
before_install: pip install six
osx_image: xcode10
script: cd src && npm run test.ci.ios
# Waiting to get access to an open source Sauce Labs account
# - stage: "UI Tests"
# env: Android="23"
# language: node_js
# os: linux
# node_js: "8"
# script:
# - npm i -g appium
# - cd demo && npm i
# - travis_retry npm run e2e -- --runType sauce.android24 --sauceLab --reuseDevice --appPath $ANDROID_PACKAGE
# - os: linux
# env:
# - iOS="12.1"
# language: node_js
# node_js: "8"
# script:
# - npm i -g appium
# - cd demo && npm run clean && npm i
# - travis_wait travis_retry npm run e2e -- --runType sauce.iPhone6.110 --sauceLab --reuseDevice --appPath $IOS_PACKAGE
android:
components:
- tools
- platform-tools
- build-tools-28.0.2
- android-28
- android-26
- extra-android-m2repository
- sys-img-armeabi-v7a-android-21
install:
- echo no | npm install -g nativescript
- tns usage-reporting disable
- tns error-reporting disable