From 54b24da8a70b07adfa689e2df0e0304f5cbcea54 Mon Sep 17 00:00:00 2001 From: Christian Noon Date: Fri, 14 Sep 2018 11:22:24 -0700 Subject: [PATCH] Updated travis-ci yaml file to use bundler and Xcode 10 --- .travis.yml | 39 +++++++++++++++++++++++++-------------- 1 file changed, 25 insertions(+), 14 deletions(-) diff --git a/.travis.yml b/.travis.yml index d58691c..c489da1 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,8 +1,9 @@ -language: objective-c -osx_image: xcode9.4 +os: osx +osx_image: xcode10 branches: only: - master + env: global: - LC_CTYPE=en_US.UTF-8 @@ -12,38 +13,48 @@ env: - MACOS_FRAMEWORK_SCHEME="Elevate macOS" - TVOS_FRAMEWORK_SCHEME="Elevate tvOS" - WATCHOS_FRAMEWORK_SCHEME="Elevate watchOS" - - IOS_SDK=iphonesimulator11.4 - - OSX_SDK=macosx10.13 - - TVOS_SDK=appletvsimulator11.4 - - WATCHOS_SDK=watchsimulator4.3 + - IOS_SDK=iphonesimulator12.0 + - OSX_SDK=macosx10.14 + - TVOS_SDK=appletvsimulator12.0 + - WATCHOS_SDK=watchsimulator5.0 matrix: - - DESTINATION="OS=11.4,name=iPhone X" SCHEME="$IOS_FRAMEWORK_SCHEME" SDK="$IOS_SDK" RUN_TESTS="YES" POD_LINT="YES" + - DESTINATION="OS=12.0,name=iPhone XS" SCHEME="$IOS_FRAMEWORK_SCHEME" SDK="$IOS_SDK" RUN_TESTS="YES" POD_LINT="YES" + - DESTINATION="OS=11.4,name=iPhone X" SCHEME="$IOS_FRAMEWORK_SCHEME" SDK="$IOS_SDK" RUN_TESTS="YES" POD_LINT="NO" - DESTINATION="OS=10.3.1,name=iPhone 7" SCHEME="$IOS_FRAMEWORK_SCHEME" SDK="$IOS_SDK" RUN_TESTS="YES" POD_LINT="NO" - DESTINATION="OS=9.3,name=iPhone 5S" SCHEME="$IOS_FRAMEWORK_SCHEME" SDK="$IOS_SDK" RUN_TESTS="YES" POD_LINT="NO" - DESTINATION="OS=8.4,name=iPhone 5" SCHEME="$IOS_FRAMEWORK_SCHEME" SDK="$IOS_SDK" RUN_TESTS="NO" POD_LINT="NO" - DESTINATION="arch=x86_64" SCHEME="$MACOS_FRAMEWORK_SCHEME" SDK="$OSX_SDK" RUN_TESTS="YES" POD_LINT="NO" - - DESTINATION="OS=11.4,name=Apple TV 4K" SCHEME="$TVOS_FRAMEWORK_SCHEME" SDK="$TVOS_SDK" RUN_TESTS="YES" POD_LINT="NO" - - DESTINATION="OS=4.3,name=Apple Watch Series 3 - 42mm" SCHEME="$WATCHOS_FRAMEWORK_SCHEME" SDK="$WATCHOS_SDK" RUN_TESTS="NO" POD_LINT="NO" + - DESTINATION="OS=12.0,name=Apple TV 4K" SCHEME="$TVOS_FRAMEWORK_SCHEME" SDK="$TVOS_SDK" RUN_TESTS="YES" POD_LINT="NO" + - DESTINATION="OS=5.0,name=Apple Watch Series 4 - 44mm" SCHEME="$WATCHOS_FRAMEWORK_SCHEME" SDK="$WATCHOS_SDK" RUN_TESTS="NO" POD_LINT="NO" + +before_install: + - gem update bundler + script: - set -o pipefail + - rvm list + - which ruby + - bundle exec gem list + - bundle exec pod --version + - bundle exec xcpretty --version - xcodebuild -version - xcodebuild -showsdks # Build Framework in Debug and Run Tests if specified - if [ $RUN_TESTS == "YES" ]; then - xcodebuild -project "$PROJECT" -scheme "$SCHEME" -sdk "$SDK" -destination "$DESTINATION" -configuration Debug ONLY_ACTIVE_ARCH=YES ENABLE_TESTABILITY=YES test | xcpretty -c; + xcodebuild -project "$PROJECT" -scheme "$SCHEME" -sdk "$SDK" -destination "$DESTINATION" -configuration Debug ONLY_ACTIVE_ARCH=YES ENABLE_TESTABILITY=YES test | bundle exec xcpretty -c; else - xcodebuild -project "$PROJECT" -scheme "$SCHEME" -sdk "$SDK" -destination "$DESTINATION" -configuration Debug ONLY_ACTIVE_ARCH=NO build | xcpretty -c; + xcodebuild -project "$PROJECT" -scheme "$SCHEME" -sdk "$SDK" -destination "$DESTINATION" -configuration Debug ONLY_ACTIVE_ARCH=NO build | bundle exec xcpretty -c; fi # Build Framework in Release and Run Tests if specified - if [ $RUN_TESTS == "YES" ]; then - xcodebuild -project "$PROJECT" -scheme "$SCHEME" -sdk "$SDK" -destination "$DESTINATION" -configuration Release ONLY_ACTIVE_ARCH=NO ENABLE_TESTABILITY=YES test | xcpretty -c; + xcodebuild -project "$PROJECT" -scheme "$SCHEME" -sdk "$SDK" -destination "$DESTINATION" -configuration Release ONLY_ACTIVE_ARCH=NO ENABLE_TESTABILITY=YES test | bundle exec xcpretty -c; else - xcodebuild -project "$PROJECT" -scheme "$SCHEME" -sdk "$SDK" -destination "$DESTINATION" -configuration Release ONLY_ACTIVE_ARCH=NO build | xcpretty -c; + xcodebuild -project "$PROJECT" -scheme "$SCHEME" -sdk "$SDK" -destination "$DESTINATION" -configuration Release ONLY_ACTIVE_ARCH=NO build | bundle exec xcpretty -c; fi # Run `pod lib lint` if specified - if [ $POD_LINT == "YES" ]; then - pod lib lint --private; + bundle exec pod lib lint --private; fi