This repository has been archived by the owner on Jul 3, 2019. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 5
/
.travis.yml
44 lines (41 loc) · 2.02 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
44
language: objective-c
osx_image: xcode8.2
env:
global:
- LC_CTYPE=en_US.UTF-8
- LANG=en_US.UTF-8
- PROJECT=ValidationComponents.xcodeproj
- IOS_FRAMEWORK_SCHEME="ValidationComponents iOS"
- OSX_FRAMEWORK_SCHEME="ValidationComponents macOS"
- TVOS_FRAMEWORK_SCHEME="ValidationComponents tvOS"
- WATCHOS_FRAMEWORK_SCHEME="ValidationComponents watchOS"
- IOS_SDK=iphonesimulator
- MACOS_SDK=macosx
- TVOS_SDK=appletvsimulator
- WATCHOS_SDK=watchsimulator
matrix:
- DESTINATION="OS=latest,name=iPhone 7" SCHEME="$IOS_FRAMEWORK_SCHEME" SDK="$IOS_SDK" CONFIGURATION="Debug" RUN_TESTS="YES" POD_LINT="YES"
- DESTINATION="arch=x86_64" SCHEME="$OSX_FRAMEWORK_SCHEME" SDK="$MACOS_SDK" CONFIGURATION="Debug" RUN_TESTS="YES" POD_LINT="NO"
- DESTINATION="OS=latest,name=Apple TV 1080p" SCHEME="$TVOS_FRAMEWORK_SCHEME" SDK="$TVOS_SDK" CONFIGURATION="Debug" RUN_TESTS="YES" POD_LINT="NO"
- DESTINATION="OS=latest,name=Apple Watch - 42mm" SCHEME="$WATCHOS_FRAMEWORK_SCHEME" SDK="$WATCHOS_SDK" CONFIGURATION="Debug" RUN_TESTS="NO" POD_LINT="NO"
before_install:
- brew update
- brew outdated carthage || brew upgrade carthage
- gem install xcpretty --pre --no-rdoc --no-ri --no-document --quiet
- gem install cocoapods --pre --no-rdoc --no-ri --no-document --quiet
- echo y | fastlane snapshot reset_simulators
script:
- set -o pipefail
- carthage update
- if [ $RUN_TESTS == "YES" ]; then
xcodebuild -project "$PROJECT" -scheme "$SCHEME" -sdk "$SDK" -destination "$DESTINATION" -configuration "$CONFIGURATION" ONLY_ACTIVE_ARCH=NO ENABLE_TESTABILITY=YES test | xcpretty -c;
else
xcodebuild -project "$PROJECT" -scheme "$SCHEME" -sdk "$SDK" -destination "$DESTINATION" -configuration "$CONFIGURATION" ONLY_ACTIVE_ARCH=NO build | xcpretty -c;
fi
- if [ $POD_LINT == "YES" ]; then
pod lib lint --quick;
fi
after_success:
- if [ $RUN_TESTS == "YES" ]; then
bash <(curl -s https://codecov.io/bash) -J '^ValidationComponents$';
fi