-
Notifications
You must be signed in to change notification settings - Fork 11
/
Copy path_skip_travis.yml
64 lines (64 loc) · 2.18 KB
/
_skip_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
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
language: swift
osx_image: xcode13.4
os: osx
branches:
only:
- "/.*/"
cache:
directories:
- Carthage
env:
global:
- LC_CTYPE=en_US.UTF-8
- LANG=en_US.UTF-8
- PROJECT=HyperwalletUISDK.xcodeproj
- IOS_FRAMEWORK_SCHEME="HyperwalletUISDK"
- IOS_UI_TESTS_SCHEME="Demo"
matrix:
- ios_version='15.5' ios_device='iPhone 13' scheme="$IOS_FRAMEWORK_SCHEME" platform='iOS
Simulator' configuration="Debug" code_coverage="YES" publish_docs="NO" only_active_arch="YES"
- ios_version='15.5' ios_device='iPhone 13' scheme="$IOS_UI_TESTS_SCHEME" platform='iOS
Simulator' configuration="XCUITest" code_coverage="NO" publish_docs="NO" only_active_arch="NO"
before_install:
# List all emulator available
- xcrun simctl list
# Update the brew and build dependencies tools
# - brew outdated carthage || brew upgrade carthage
- brew update && brew upgrade carthage
- carthage version
- carthage update --platform ios --use-xcframeworks --no-use-binaries --cache-builds
- gem i slather
# Install build output formatting tool
- gem install xcpretty
# Force to update the Swiftlint to the last stable version
- brew outdated swiftlint || brew upgrade swiftlint
# Print the swiftlint version
- swiftlint version
# Installing Jazzy
- gem install jazzy
# Installing Sourcekitten
- brew install sourcekitten
script: |
set -o pipefail
set -e
# Define the destination emulator
destination="platform=$platform,OS=$ios_version,name=$ios_device"
# Build and test Framework in Debug
xcodebuild -enableCodeCoverage "$code_coverage" clean build test -project "$PROJECT" \
-scheme "$scheme" \
-destination "$destination" \
-configuration "$configuration" ONLY_ACTIVE_ARCH="$only_active_arch" ENABLE_TESTABILITY=YES CODE_SIGN_IDENTITY="" CODE_SIGNING_REQUIRED=NO \
| xcpretty --color
# Lint - Add `--strict` to fail for warning and violation
swiftlint lint --strict --reporter json
after_success:
- |
if [ "$code_coverage" == "YES" ]; then
slather;
fi
if [ "$publish_docs" == "YES" ]; then
if [ $TRAVIS_BRANCH = 'master' ] && [ $TRAVIS_PULL_REQUEST = 'false' ]; then
make docs;
sh ./Scripts/travisPublishDocs.sh;
fi
fi