-
-
Notifications
You must be signed in to change notification settings - Fork 153
50 lines (50 loc) · 1.47 KB
/
build_and_test.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
name: Build and Test
on:
workflow_dispatch: {}
pull_request:
branches:
- main
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true
jobs:
build:
name: Build and test
runs-on: macos-14
continue-on-error: true
strategy:
matrix:
include:
- xcode: 15.2
- xcode: 14.3.1
env:
DEVELOPER_DIR: /Applications/Xcode_${{ matrix.xcode }}.app/Contents/Developer
steps:
- name: Checkout
uses: actions/checkout@v4
with:
submodules: recursive
- name: Check for changed files
uses: dorny/paths-filter@v3
id: changes
with:
filters: |
src:
- '.github/workflows/build_and_test.yml'
- 'Sources/**'
- '!Sources/Runestone/Documentation.docc/**'
- 'Tests/**'
- name: Build
if: steps.changes.outputs.src == 'true'
run: |
xcodebuild build-for-testing\
-scheme Runestone\
-sdk iphonesimulator\
-destination "platform=iOS Simulator,name=generic/platform=iOS Simulator,OS=latest"
- name: Test
if: steps.changes.outputs.src == 'true'
run: |
xcodebuild test-without-building\
-scheme Runestone\
-sdk iphonesimulator\
-destination "platform=iOS Simulator,name=generic/platform=iOS Simulator,OS=latest"