.travis.yml 2.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354
  1. language: objective-c
  2. osx_image: xcode9
  3. env:
  4. global:
  5. - LC_CTYPE=en_US.UTF-8
  6. - LANG=en_US.UTF-8
  7. notifications:
  8. email: false
  9. before_install:
  10. - env
  11. - locale
  12. - gem install cocoapods --no-rdoc --no-ri --no-document --quiet
  13. - gem install xcpretty --no-rdoc --no-ri --no-document --quiet
  14. - pod --version
  15. - pod setup --silent > /dev/null
  16. - pod repo update --silent
  17. - xcpretty --version
  18. - xcodebuild -version
  19. - xcodebuild -showsdks
  20. script:
  21. - set -o pipefail
  22. - echo Check if the library described by the podspec can be built
  23. - pod lib lint --allow-warnings
  24. - echo Build as static library
  25. - xcodebuild clean build -workspace SDWebImage.xcworkspace -scheme 'SDWebImage iOS static' -sdk iphonesimulator PLATFORM_NAME=iphonesimulator -configuration Debug | xcpretty -c
  26. - xcodebuild clean build -workspace SDWebImage.xcworkspace -scheme 'SDWebImage watchOS static' -sdk watchsimulator -configuration Debug | xcpretty -c
  27. - echo Build as dynamic framework
  28. - xcodebuild clean build -workspace SDWebImage.xcworkspace -scheme 'SDWebImage OSX' -sdk macosx -configuration Debug | xcpretty -c
  29. - xcodebuild clean build -workspace SDWebImage.xcworkspace -scheme 'SDWebImage iOS' -sdk iphonesimulator PLATFORM_NAME=iphonesimulator -configuration Debug | xcpretty -c
  30. - xcodebuild clean build -workspace SDWebImage.xcworkspace -scheme 'SDWebImage tvOS' -sdk appletvsimulator -configuration Debug | xcpretty -c
  31. - xcodebuild clean build -workspace SDWebImage.xcworkspace -scheme 'SDWebImage watchOS' -sdk watchsimulator -configuration Debug | xcpretty -c
  32. - echo Build the Demo apps
  33. - xcodebuild build -workspace SDWebImage.xcworkspace -scheme 'SDWebImage OSX Demo' -sdk macosx -configuration Debug | xcpretty -c
  34. - xcodebuild build -workspace SDWebImage.xcworkspace -scheme 'SDWebImage iOS Demo' -configuration Debug -destination 'name=iPhone 6s' | xcpretty -c
  35. - xcodebuild build -workspace SDWebImage.xcworkspace -scheme 'SDWebImage TV Demo' -sdk appletvsimulator -configuration Debug | xcpretty -c
  36. - xcodebuild build -workspace SDWebImage.xcworkspace -scheme 'SDWebImage Watch Demo' -configuration Debug -destination 'name=iPhone 6s' | xcpretty -c
  37. - echo Run the tests
  38. - pod install --project-directory=Tests
  39. - xcodebuild clean -workspace SDWebImage.xcworkspace -scheme 'SDWebImage iOS' -sdk iphonesimulator PLATFORM_NAME=iphonesimulator -configuration Debug | xcpretty -c
  40. - xcodebuild clean -workspace SDWebImage.xcworkspace -scheme 'SDWebImage iOS Demo' -configuration Debug -destination 'name=iPhone 6s' | xcpretty -c
  41. - xcodebuild test -workspace SDWebImage.xcworkspace -scheme 'Tests' -sdk iphonesimulator -destination 'platform=iOS Simulator,name=iPhone 6,OS=latest' -configuration Debug | xcpretty -c
  42. after_success:
  43. - bash <(curl -s https://codecov.io/bash)