Skip to content

Commit 63f915e

Browse files
committed
Add github workflow to run the tests
1 parent 811ac7c commit 63f915e

1 file changed

Lines changed: 42 additions & 0 deletions

File tree

.github/workflows/test.yml

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
name: Test
2+
3+
on:
4+
push:
5+
branches: [ main, develop ]
6+
pull_request:
7+
branches: [ main, develop ]
8+
9+
jobs:
10+
test:
11+
name: Test on ${{ matrix.destination }}
12+
runs-on: macos-15
13+
14+
strategy:
15+
fail-fast: false
16+
matrix:
17+
include:
18+
- destination: 'platform=iOS Simulator,name=iPhone 16'
19+
name: iOS
20+
- destination: 'platform=watchOS Simulator,name=Apple Watch Series 11 (42mm)'
21+
name: watchOS
22+
23+
steps:
24+
- name: Checkout
25+
uses: actions/checkout@v4
26+
27+
- name: Show Xcode version
28+
run: xcodebuild -version
29+
30+
- name: Build and Test
31+
run: |
32+
xcodebuild test \
33+
-scheme MultiPicker \
34+
-destination '${{ matrix.destination }}' \
35+
-enableCodeCoverage YES
36+
37+
- name: Upload coverage reports to Codecov
38+
if: matrix.name == 'iOS'
39+
uses: codecov/codecov-action@v4
40+
with:
41+
fail_ci_if_error: false
42+
token: ${{ secrets.CODECOV_TOKEN }}

0 commit comments

Comments
 (0)