forked from facebookincubator/SocketRocket
-
Notifications
You must be signed in to change notification settings - Fork 5
/
.travis.yml
43 lines (43 loc) · 1.24 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
branches:
only:
- master
language: objective-c
os: osx
osx_image: xcode7.3
env:
matrix:
- TEST_TYPE=iOS
- TEST_TYPE=OSX
- TEST_TYPE=tvOS
- TEST_TYPE=CocoaPods
- TEST_TYPE=Carthage
before_install:
- |
if [ "$TEST_TYPE" = iOS ] || [ "$TEST_TYPE" = OSX ] || [ "$TEST_TYPE" = tvOS ]; then
bundle install
elif [ "$TEST_TYPE" = Carthage ]; then
brew update
brew install carthage || brew upgrade carthage
fi
install:
- |
if [ "$TEST_TYPE" = iOS ]; then
./TestSupport/setup_env.sh .env
fi
script:
- |
if [ "$TEST_TYPE" = iOS ]; then
set -o pipefail
xcodebuild -project SocketRocket.xcodeproj -scheme "SocketRocket-iOS" -sdk iphonesimulator build test
elif [ "$TEST_TYPE" = OSX ]; then
set -o pipefail
xcodebuild -project SocketRocket.xcodeproj -scheme "SocketRocket-macOS" -sdk macosx build | xcpretty -c
elif [ "$TEST_TYPE" = tvOS ]; then
set -o pipefail
xcodebuild -project SocketRocket.xcodeproj -scheme "SocketRocket-tvOS" -sdk appletvsimulator build | xcpretty -c
elif [ "$TEST_TYPE" = CocoaPods ]; then
pod lib lint SocketRocket.podspec
pod lib lint --use-libraries SocketRocket.podspec
elif [ "$TEST_TYPE" = Carthage ]; then
carthage build --no-skip-current
fi