-
Notifications
You must be signed in to change notification settings - Fork 10
/
.travis.yml
43 lines (37 loc) · 1.53 KB
/
.travis.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
language: objective-c
matrix:
include:
- osx_image: xcode7.3
- osx_image: xcode8.2
before_install:
- rvm install 2.4.0
install:
- gem install jazzy
- gem install cocoapods
- gem install slather
before_script:
- rm -rf ~/Library/Developer/Xcode/DerivedData
script:
# Test that the framework can be installed and built, and passes all unit tests
- travis_wait pod update
- carthage update
- pod lib lint --allow-warnings
- xcodebuild -scheme 'BMSAnalytics iOS' clean build CODE_SIGN_IDENTITY="" CODE_SIGNING_REQUIRED=NO
- xcodebuild -scheme 'BMSAnalytics watchOS' clean build CODE_SIGN_IDENTITY="" CODE_SIGNING_REQUIRED=NO
# For Xcode 7, test with iOS 8.1
- if [[ "${TRAVIS_JOB_NUMBER}" = *".1"* ]]; then
travis_retry xcodebuild test -workspace BMSAnalytics.xcworkspace -scheme 'BMSAnalytics Tests' -destination 'platform=iOS Simulator,name=iPhone 6,OS=8.1';
fi
# For Xcode 8, test with iOS 10.1
- if [[ "${TRAVIS_JOB_NUMBER}" = *".2"* ]]; then
travis_retry xcodebuild test -workspace BMSAnalytics.xcworkspace -scheme 'BMSAnalytics Tests' -destination 'platform=iOS Simulator,name=iPhone 6,OS=10.1';
fi
# When merging or pushing to the master branch, release a new version and publish the API documentation
- if [ "${TRAVIS_PULL_REQUEST}" = "false" ] && [ "${TRAVIS_BRANCH}" = "master" ] && [[ "${TRAVIS_JOB_NUMBER}" = *".2"* ]]; then
bash scripts/release.sh;
bash scripts/publish-docs.sh;
fi
after_success:
- if [[ "${TRAVIS_JOB_NUMBER}" = *".2"* ]]; then
slather;
fi