Skip to content

Commit

Permalink
fix: travis file
Browse files Browse the repository at this point in the history
  • Loading branch information
Zdravko Branzov authored and Zdravko Branzov committed Jun 5, 2018
1 parent 260bc68 commit ca01921
Show file tree
Hide file tree
Showing 2 changed files with 40 additions and 63 deletions.
1 change: 0 additions & 1 deletion .gitattributes

This file was deleted.

102 changes: 40 additions & 62 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,32 +1,49 @@
branches:
only:
- next
- master
env:
global:
- ANDROID_PACKAGE='app-debug.apk'
- ANDROID_PACKAGE_NEXT='demo-debug-next.apk'
- ANDROID_PACKAGE='facebook-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_NEXT?overwrite=true"
- IOS_PACKAGE_NEXT='demo-next.zip'
- 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_NEXT?overwrite=true"
- IOS_SAUCE_STORAGE="https://saucelabs.com/rest/v1/storage/$SAUCE_USER/$IOS_PACKAGE?overwrite=true"

matrix:
include:
- stage: "Build"
- stage: "Lint"
language: node_js
os: linux
node_js: "6"
script: cd src && npm run ci.tslint && cd ../demo && npm run ci.tslint && cd ../demo-angular && npm run ci.tslint
- stage: "WebPack and Build"
os: osx
env:
- WebpackiOS="11"
osx_image: xcode9.2
language: node_js
node_js: "6"
jdk: oraclejdk8
script: cd demo && npm run build.plugin && npm i && tns build ios --env.uglify && cd ../demo-angular && npm run build.plugin && npm i && tns build ios --env.uglify --env.aot
- language: android
os: linux
env:
- WebpackAndroid="26"
jdk: oraclejdk8
before_install: nvm install 6
script:
- cd demo && npm run build.plugin && cd ../src && tns plugin build && cd ../demo && npm i && tns build android --env.uglify --env.snapshot
- cd ../demo-angular && npm i && tns build android --env.uglify --env.snapshot --env.aot
- language: android
env:
- BuildAndroid="26"
language: android
os: linux
jdk: oraclejdk8
before_install:
- nvm install 8.9.4
before_script:
- cd ../demo && tns platform add android@next
- cd ../demo-angular && tns platform add android@next
before_install: nvm install 8.9.4
script:
- cd ../demo && npm run ci.android.build && cd ../demo-angular && npm run ci.android.build
- "curl -u $SAUCE_USER:$SAUCE_KEY -X POST -H 'Content-Type: application/octet-stream' $ANDROID_SAUCE_STORAGE --data-binary @$ANDROID_PACKAGE_FOLDER/$ANDROID_PACKAGE"
- cd demo && npm run ci.android.build && cd ../demo-angular && npm run ci.android.build
- "curl -u $SAUCE_USER:$SAUCE_KEY -X POST -H 'Content-Type: application/octet-stream' $ANDROID_SAUCE_STORAGE --data-binary @$ANDROID_PACKAGE_FOLDER/app-debug.apk"
- os: osx
env:
- BuildiOS="11"
Expand All @@ -35,55 +52,29 @@ matrix:
language: node_js
node_js: "8"
jdk: oraclejdk8
before_script:
- cd ../demo && tns platform add ios@next
- cd ../demo-angular && tns platform add ios@next
script:
- cd ../demo && npm run ci.ios.build && cd ../demo-angular && npm run ci.ios.build
- cd $IOS_PACKAGE_FOLDER && zip -r $IOS_PACKAGE_NEXT 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_NEXT"
- os: osx
env:
- Webpack="iOS"
osx_image: xcode9.2
language: node_js
node_js: "6"
jdk: oraclejdk8
before_script:
- cd ../demo && tns platform add ios@next
- cd ../demo-angular && tns platform add ios@next
script: cd ../demo && npm run build.plugin && npm i && tns build ios --bundle --env.uglify && cd ../demo-angular && npm i && tns build ios --bundle --env.uglify --env.aot
- os: linux
language: android
env:
- Webpack="Android"
jdk: oraclejdk8
before_install: nvm install 6.10.3
before_script:
- cd ../demo && tns platform add android@next
- cd ../demo-angular && tns platform add android@next
script: cd ../demo && npm run build.plugin && npm i && tns build android --bundle --env.uglify --env.snapshot && cd ../demo-angular && npm i && tns build android --bundle --env.uglify --env.snapshot --env.aot
- cd demo && npm run ci.ios.build && cd ../demo-angular && npm run ci.ios.build
- 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"
- stage: "UI Tests"
env:
- Android="23"
- Android="23"
language: node_js
os: linux
node_js: "6"
install: true
script:
- npm i -g appium
- cd demo && npm i
- travis_wait travis_retry npm run e2e -- --runType android23 --sauceLab --reuseDevice --appPath $ANDROID_PACKAGE_NEXT
- travis_retry npm run e2e -- --runType android23 --sauceLab --reuseDevice --appPath $ANDROID_PACKAGE
- os: linux
env:
- iOS="10"
language: node_js
node_js: "6"
install: true
script:
- npm i -g appium
- cd demo && npm i
- travis_wait travis_retry npm run e2e -- --runType sim103iPhone6 --sauceLab --reuseDevice --appPath $IOS_PACKAGE_NEXT
- travis_wait travis_retry npm run e2e -- --runType sim103iPhone6 --sauceLab --reuseDevice --appPath $IOS_PACKAGE

android:
components:
Expand All @@ -104,19 +95,6 @@ cache:
- $HOME/.gradle/wrapper/

install:
- npm install -g nativescript@next
- npm install -g nativescript
- tns usage-reporting disable
- tns error-reporting disable
- cd src
- npm uninstall tns-core-modules -D && npm install tns-core-modules@next -D
- npm uninstall nativescript-angular -D && npm install nativescript-angular@next -D
- cd ../demo
- npm uninstall tns-core-modules -P && npm install tns-core-modules@next -P
- npm uninstall nativescript-dev-webpack -D && npm install nativescript-dev-webpack@next -D
- npm uninstall nativescript-dev-typescript -D && npm install nativescript-dev-typescript@next -D
- cd ../demo-angular
- npm uninstall tns-core-modules -P && npm install tns-core-modules@next -P
- npm uninstall nativescript-angular -P && npm install nativescript-angular@next -P
- npm uninstall nativescript-dev-webpack -D && npm install nativescript-dev-webpack@next -D
- npm uninstall nativescript-dev-typescript -D && npm install nativescript-dev-typescript@next -D

- tns error-reporting disable

0 comments on commit ca01921

Please sign in to comment.