From f128e437301f739ac850a1c803ec5b347c5e49a4 Mon Sep 17 00:00:00 2001 From: Max Howell Date: Wed, 10 Oct 2018 19:47:59 -0400 Subject: [PATCH] [ci] Run `pod lib lint` for everything we support --- .travis.yml | 134 +++++++++++++++++++++++++++++----------------- Cartfile.resolved | 4 +- 2 files changed, 87 insertions(+), 51 deletions(-) diff --git a/.travis.yml b/.travis.yml index bbd8b7a..13e7e96 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,52 +1,88 @@ -os: osx -language: objective-c -matrix: +branches: + only: + - master +stages: + - lint + - carthage + - test +jobs: include: - - {osx_image: xcode8.3, env: 'PLAT=macOS SWFT=3.1 DST="arch=x86_64"'} - - {osx_image: xcode8.3, env: 'PLAT=iOS SWFT=3.1 DST="OS=10.3.1,name=iPhone SE"'} - - {osx_image: xcode8.3, env: 'PLAT=tvOS SWFT=3.1 DST="OS=10.2,name=Apple TV 1080p"'} - - {osx_image: xcode8.3, env: 'PLAT=watchOS SWFT=3.1 DST="OS=3.2,name=Apple Watch - 38mm"'} + - &pod + stage: lint + osx_image: xcode8.3 + env: SWIFT=3.1 + name: pod lib lint --swift-version=3.1 + os: osx + language: objective-c + cache: + - cocoapods + - directories: + - Carthage + before_install: + gem install cocoapods --prerelease --version 1.6.0.beta.1 + install: + carthage bootstrap --no-build PromiseKit + script: | + cd Carthage/Checkouts/PromiseKit + mv .github/PromiseKit.podspec . + rm -rf Extensions/Alamofire/Sources + cp -R ../../../Sources Extensions/Alamofire + pod lib lint --subspec=PromiseKit/Alamofire --fail-fast --swift-version=$SWIFT + - <<: *pod + osx_image: xcode9.2 + env: SWIFT=3.2 + name: pod lib lint --swift-version=3.2 + - <<: *pod + osx_image: xcode9.4 + env: SWIFT=3.3 + name: pod lib lint --swift-version=3.3 + - <<: *pod + osx_image: xcode10 + env: SWIFT=3.4 + name: pod lib lint --swift-version=3.4 + - <<: *pod + osx_image: xcode9.2 + env: SWIFT=4.0 + name: pod lib lint --swift-version=4.0 + - <<: *pod + osx_image: xcode9.4 + env: SWIFT=4.1 + name: pod lib lint --swift-version=4.1 + - <<: *pod + osx_image: xcode10 + env: SWIFT=4.2 + name: pod lib lint --swift-version=4.2 - - {osx_image: xcode9.3, env: 'PLAT=macOS SWFT=3.2 DST="arch=x86_64"'} - - {osx_image: xcode9.3, env: 'PLAT=iOS SWFT=3.2 DST="OS=11.2,name=iPhone SE"'} - - {osx_image: xcode9.3, env: 'PLAT=tvOS SWFT=3.2 DST="OS=11.2,name=Apple TV"'} - - {osx_image: xcode9.3, env: 'PLAT=watchOS SWFT=3.2 DST="OS=4.2,name=Apple Watch - 38mm"'} + - stage: carthage + osx_image: xcode10 + name: Carthage / watchOS + os: osx + language: objective-c + script: + carthage bootstrap --platform watchOS + cache: + directories: + - Carthage - - {osx_image: xcode9.4, env: 'PLAT=macOS SWFT=3.3 DST="arch=x86_64"'} - - {osx_image: xcode9.4, env: 'PLAT=iOS SWFT=3.3 DST="OS=11.4,name=iPhone 5s"'} - - {osx_image: xcode9.4, env: 'PLAT=tvOS SWFT=3.3 DST="OS=11.4,name=Apple TV"'} - - {osx_image: xcode9.4, env: 'PLAT=watchOS SWFT=3.3 DST="OS=4.3,name=Apple Watch - 38mm"'} - - - {osx_image: xcode10, env: 'PLAT=macOS SWFT=3.4 DST="arch=x86_64"'} - - {osx_image: xcode10, env: 'PLAT=iOS SWFT=3.4 DST="OS=11.4,name=iPhone 5s"'} - - {osx_image: xcode10, env: 'PLAT=tvOS SWFT=3.4 DST="OS=11.4,name=Apple TV"'} - - {osx_image: xcode10, env: 'PLAT=watchOS SWFT=3.4 DST="OS=5.0,name=Apple Watch Series 3 - 42mm"'} - - - {osx_image: xcode9.2, env: 'PLAT=macOS SWFT=4.0 DST="arch=x86_64"'} - - {osx_image: xcode9.2, env: 'PLAT=iOS SWFT=4.0 DST="OS=11.2,name=iPhone SE"'} - - {osx_image: xcode9.2, env: 'PLAT=tvOS SWFT=4.0 DST="OS=11.2,name=Apple TV"'} - - {osx_image: xcode9.2, env: 'PLAT=watchOS SWFT=4.0 DST="OS=4.2,name=Apple Watch - 38mm"'} - - - {osx_image: xcode9.4, env: 'PLAT=macOS SWFT=4.1 DST="arch=x86_64" TEST=1'} - - {osx_image: xcode9.4, env: 'PLAT=iOS SWFT=4.1 DST="OS=11.4,name=iPhone 5s" TEST=1'} - - {osx_image: xcode9.4, env: 'PLAT=tvOS SWFT=4.1 DST="OS=11.4,name=Apple TV" TEST=1'} - - {osx_image: xcode9.4, env: 'PLAT=watchOS SWFT=4.1 DST="OS=4.3,name=Apple Watch - 38mm"'} - - - {osx_image: xcode10, env: 'PLAT=macOS SWFT=4.2 DST="arch=x86_64"'} - - {osx_image: xcode10, env: 'PLAT=iOS SWFT=4.2 DST="OS=11.4,name=iPhone 5s"'} - - {osx_image: xcode10, env: 'PLAT=tvOS SWFT=4.2 DST="OS=11.4,name=Apple TV"'} - - {osx_image: xcode10, env: 'PLAT=watchOS SWFT=4.2 DST="OS=5.0,name=Apple Watch Series 3 - 42mm"'} -cache: - directories: - - Carthage -before_install: - - carthage bootstrap --cache-builds --no-use-binaries --platform $PLAT --verbose -install: - - xcodebuild -scheme PMKAlamofire -target PMKAlamofire -quiet -destination "$DST" SWIFT_VERSION=$SWFT SWIFT_TREAT_WARNINGS_AS_ERRORS=YES build - - if [ "$TEST" == "1" ]; then - xcodebuild -scheme PMKAlamofire -target PMKAFTests -quiet -destination "$DST" build; - fi -script: - - if [ "$TEST" == "1" ]; then - xcodebuild -scheme PMKAlamofire -quiet -destination "$DST" test; - fi + - &test + stage: test + osx_image: xcode10 + name: macOS Tests + env: DST='arch=x86_64' PLAT=macOS + os: osx + language: objective-c + cache: + directories: + - Carthage + before_install: + carthage bootstrap --cache-builds --no-use-binaries --platform $PLAT + install: + xcodebuild -scheme PMKAlamofire -target PMKAlamofire -quiet -destination "$DST" SWIFT_TREAT_WARNINGS_AS_ERRORS=YES build + script: + xcodebuild -scheme PMKAlamofire -quiet -destination "$DST" test + - <<: *test + env: DST='OS=12.0,name=iPhone SE' PLAT=iOS + name: iOS Tests + - <<: *test + env: DST='OS=12.0,name=Apple TV' PLAT=tvOS + name: tvOS Tests diff --git a/Cartfile.resolved b/Cartfile.resolved index b8ec46f..a2065e6 100644 --- a/Cartfile.resolved +++ b/Cartfile.resolved @@ -1,3 +1,3 @@ -github "Alamofire/Alamofire" "4.7.2" +github "Alamofire/Alamofire" "4.7.3" github "AliSoftware/OHHTTPStubs" "6.1.0" -github "mxcl/PromiseKit" "6.3.3" +github "mxcl/PromiseKit" "6.5.2"