-
Notifications
You must be signed in to change notification settings - Fork 179
/
.travis.yml
37 lines (36 loc) · 1.6 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
language: objective-c
osx_image: xcode10.2
before_install:
- gem install xcov -v 0.11.3
- gem install slather danger danger-swiftlint danger-xcov
env:
global:
- LC_CTYPE=en_US.UTF-8
- LANG=en_US.UTF-8
- PROJECT=AudioPlayer/AudioPlayer.xcodeproj
- IOS_FRAMEWORK_SCHEME="AudioPlayer iOS"
- OSX_FRAMEWORK_SCHEME="AudioPlayer OSX"
- TVOS_FRAMEWORK_SCHEME="AudioPlayer tvOS"
- IOS_SDK=iphonesimulator12.2
- OSX_SDK=macosx10.14
- TVOS_SDK=appletvsimulator12.2
matrix:
- DESTINATION="OS=12.2,name=iPhone 8" SCHEME="$IOS_FRAMEWORK_SCHEME" SDK="$IOS_SDK" RUN_TESTS="YES"
- DESTINATION="arch=x86_64" SCHEME="$OSX_FRAMEWORK_SCHEME" SDK="$OSX_SDK" RUN_TESTS="NO"
- DESTINATION="OS=12.2,name=Apple TV 4K (at 1080p)" SCHEME="$TVOS_FRAMEWORK_SCHEME" SDK="$TVOS_SDK" RUN_TESTS="NO"
script:
- set -o pipefail
- xcodebuild -version
- xcodebuild -showsdks
# Build Framework in Debug and Run Tests if specified
- if [ $RUN_TESTS == "YES" ]; then
xcodebuild -project "$PROJECT" -scheme "$SCHEME" -sdk "$SDK" -destination "$DESTINATION" build test | xcpretty -c;
slather coverage --input-format profdata -i ".*Tests.*" --scheme "AudioPlayer iOS" AudioPlayer/AudioPlayer.xcodeproj;
bash <(curl -s https://codecov.io/bash) -f cobertura.xml;
danger;
else
xcodebuild -project "$PROJECT" -scheme "$SCHEME" -sdk "$SDK" -destination "$DESTINATION" build | xcpretty -c;
fi
notifications:
slack:
secure: JGuQNTO7Aeu4Jtm3enUT/TSoDeIkcBCFH4He3QfnBS19VVDPb3mxX+Qfy2HY5EG6u1IcNbBuBzhjGb1phBrCoDdQM7AWac24hFku1mVQykxW6wgrAVAOYfvffZmBzgno3OyEzODF4MgZJKR24B577YplsBCa64lWAkAGceCZGHo=