-
Notifications
You must be signed in to change notification settings - Fork 0
61 lines (51 loc) · 1.48 KB
/
Copy pathci.yml
File metadata and controls
61 lines (51 loc) · 1.48 KB
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
name: macOS CI
on:
push:
branches: [ main, master ]
paths-ignore:
- '**/*.md'
- 'DOCS/**'
pull_request:
branches: [ "**" ]
paths-ignore:
- '**/*.md'
- 'DOCS/**'
workflow_dispatch:
concurrency:
group: macos-ci-${{ github.ref }}
cancel-in-progress: true
jobs:
build-and-test:
name: Build and Test (macOS)
runs-on: macos-14
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Select Xcode
uses: maxim-lobanov/setup-xcode@v1
with:
xcode-version: latest-stable
- name: Cache SwiftPM build artifacts
uses: actions/cache@v4
with:
path: |
~/.swiftpm
.build
key: ${{ runner.os }}-swiftpm-${{ hashFiles('Package.swift', 'Package.resolved') }}
restore-keys: |
${{ runner.os }}-swiftpm-
- name: Resolve dependencies
run: swift package resolve
- name: Build package (release)
run: swift build --configuration release --build-tests -Xswiftc -enable-testing
- name: Run unit tests (release)
run: swift test --configuration release -Xswiftc -enable-testing
- name: Run benchmark tests (release)
run: |
swift test --configuration release \
--filter '^SpecificationKitBenchmarks\.' \
-Xswiftc -enable-testing
- name: Build DemoApp (release)
run: |
cd DemoApp
swift build --configuration release