diff --git a/.travis.yml b/.travis.yml index b374bd9f9..c9e1bdadc 100644 --- a/.travis.yml +++ b/.travis.yml @@ -3,37 +3,41 @@ branches: - master language: objective-c os: osx -osx_image: xcode7 +osx_image: xcode7.1 cache: - cocoapods env: matrix: - - TEST_TYPE=ios - - TEST_TYPE=osx - - TEST_TYPE=cocoapods + - TEST_TYPE=iOS + - TEST_TYPE=OSX + - TEST_TYPE=tvOS + - TEST_TYPE=CocoaPods before_install: - | - if [ "$TEST_TYPE" = ios ] || [ "$TEST_TYPE" = osx ]; then + if [ "$TEST_TYPE" = iOS ] || [ "$TEST_TYPE" = OSX ] || [ "$TEST_TYPE" = tvOS ]; then gem install xcpretty -N --no-ri --no-rdoc - elif [ "$TEST_TYPE" = cocoapods ]; then + elif [ "$TEST_TYPE" = CocoaPods ]; then gem install cocoapods --pre --quiet --no-ri --no-rdoc pod setup --silent pod repo update --silent fi script: - | - if [ "$TEST_TYPE" = ios ]; then + if [ "$TEST_TYPE" = iOS ]; then set -o pipefail xcodebuild test -project Bolts.xcodeproj -sdk iphonesimulator -scheme Bolts-iOS -configuration Debug -destination "platform=iOS Simulator,name=iPhone 4s" -destination "platform=iOS Simulator,name=iPhone 6 Plus" GCC_INSTRUMENT_PROGRAM_FLOW_ARCS=YES GCC_GENERATE_TEST_COVERAGE_FILES=YES | xcpretty -c - elif [ "$TEST_TYPE" = osx ]; then + elif [ "$TEST_TYPE" = OSX ]; then set -o pipefail xcodebuild test -project Bolts.xcodeproj -sdk macosx -scheme Bolts-OSX -configuration Debug GCC_INSTRUMENT_PROGRAM_FLOW_ARCS=YES GCC_GENERATE_TEST_COVERAGE_FILES=YES | xcpretty -c - elif [ "$TEST_TYPE" = cocoapods ]; then + elif [ "$TEST_TYPE" = OSX ]; then + set -o pipefail + xcodebuild test -project Bolts.xcodeproj -scheme Bolts-tvOS -configuration Debug GCC_INSTRUMENT_PROGRAM_FLOW_ARCS=YES GCC_GENERATE_TEST_COVERAGE_FILES=YES | xcpretty -c + elif [ "$TEST_TYPE" = CocoaPods ]; then pod lib lint Bolts.podspec pod lib lint --use-libraries Bolts.podspec fi after_success: - | - if [ "$TEST_TYPE" = ios ] || [ "$TEST_TYPE" = osx ]; then + if [ "$TEST_TYPE" = iOS ] || [ "$TEST_TYPE" = OSX ] || [ "$TEST_TYPE" = tvOS ]; then bash <(curl -s https://codecov.io/bash) fi