-
-
Notifications
You must be signed in to change notification settings - Fork 9
57 lines (53 loc) · 1.87 KB
/
tests.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
name: Tests
on:
workflow_dispatch:
push:
branches: [main]
pull_request:
branches: [main]
jobs:
swift_test:
strategy:
matrix:
xcode_version: ['13.1']
runs-on: macos-12
env:
DEVELOPER_DIR: /Applications/Xcode_${{ matrix.xcode_version }}.app
steps:
- name: Check out STKAudioKit
uses: actions/checkout@v2
- name: Build STKAudioKit
run: |
set -euo pipefail
xcodebuild -destination 'platform=OS X,arch=x86_64' -scheme STKAudioKit -enableAddressSanitizer YES clean build | xcpretty
- name: Run Tests (ASAN)
run: |
set -euo pipefail
xcodebuild -destination 'platform=OS X,arch=x86_64' -scheme STKAudioKit -enableAddressSanitizer YES test | xcpretty
build_demo:
name: Build ${{ matrix.scheme }} (Xcode ${{ matrix.xcode_version }})
# NOTE: macos-latest is NOT equivalent to macos-12 as of September 2022.
# Source: https://docs.github.com/en/actions/using-github-hosted-runners/about-github-hosted-runners#supported-runners-and-hardware-resources
runs-on: macos-12
needs: [swift_test]
strategy:
# Disabling fail-fast ensures that the job will run all configurations of the matrix, even if one fails.
fail-fast: false
matrix:
xcode_version:
- '13.2' # swift 5.5
- '13.4' # swift 5.6
steps:
- name: Build Demo
uses: AudioKit/ci/.github/actions/build-demo@main
with:
project: Demo/STKAudioKitDemo.xcodeproj
scheme: ${{ 'STKAudioKit' }}
xcode_version: ${{ matrix.xcode_version }}
# Send notification to Discord on failure.
send_notification:
name: Send Notification
uses: AudioKit/ci/.github/workflows/send_notification.yml@main
needs: [swift_test, build_demo]
if: ${{ failure() && github.ref == 'refs/heads/main' }}
secrets: inherit