Add iOS CI #2340
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: CI | |
on: | |
push: | |
branches: | |
- main | |
- 6.x.x | |
pull_request: | |
release: | |
types: [published] | |
workflow_dispatch: | |
env: | |
ENABLE_TIMING_TESTS: "false" | |
AWS_LOG_LEVEL: "trace" | |
SOTO_CORE_STRICT_CONCURRENCY: "true" | |
jobs: | |
macos: | |
runs-on: macOS-13 | |
timeout-minutes: 15 | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: SPM tests | |
run: swift test --enable-code-coverage --parallel | |
- name: Convert coverage files | |
run: | | |
xcrun llvm-cov export -format "lcov" \ | |
.build/debug/soto-corePackageTests.xctest/Contents/MacOs/soto-corePackageTests \ | |
-ignore-filename-regex="\/Tests\/" \ | |
-instr-profile=.build/debug/codecov/default.profdata > info.lcov | |
- name: Upload to codecov.io | |
uses: codecov/codecov-action@v4 | |
with: | |
file: info.lcov | |
ios: | |
runs-on: macOS-latest | |
timeout-minutes: 15 | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Xcodebuild | |
run: | | |
xcodebuild -scheme soto-core-Package -quiet -destination 'platform=iOS Simulator,name=iPhone 15' | |
xcodebuild test -scheme soto-core-Package -destination 'platform=iOS Simulator,name=iPhone 15' | |
linux: | |
runs-on: ubuntu-latest | |
timeout-minutes: 15 | |
strategy: | |
matrix: | |
image: | |
- 'swift:5.9' | |
- 'swift:5.10' | |
- 'swift:6.0' | |
container: | |
image: ${{ matrix.image }} | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Test | |
run: | | |
swift --version | |
swift test --enable-code-coverage | |
- name: Convert coverage files | |
run: | | |
llvm-cov export -format="lcov" \ | |
.build/debug/soto-corePackageTests.xctest \ | |
-ignore-filename-regex="\/Tests\/" \ | |
-instr-profile .build/debug/codecov/default.profdata > info.lcov | |
- name: Upload to codecov.io | |
uses: codecov/codecov-action@v4 | |
with: | |
file: info.lcov |