Skip to content

Commit 5cd04d3

Browse files
author
Garrett Moseke
committed
ci: Add PR jobs for code formatting, macOS testing, and linux testing
1 parent 5f846e4 commit 5cd04d3

File tree

1 file changed

+35
-0
lines changed

1 file changed

+35
-0
lines changed

.github/workflows/pull_request.yml

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
name: Pull Requst
2+
3+
on: [pull_request]
4+
5+
jobs:
6+
lint:
7+
name: Lint Formatting
8+
runs-on: ubuntu-latest
9+
steps:
10+
- uses: actions/checkout@v4
11+
- name: Lint Formatting
12+
run: swift format lint --recursive --strict .
13+
14+
test-macos:
15+
name: Test macOS using Xcode latest-stable
16+
runs-on: macos-latest
17+
steps:
18+
- uses: maxim-lobanov/setup-xcode@v1
19+
with:
20+
xcode-version: latest-stable
21+
- uses: actions/checkout@v4
22+
- name: Run tests
23+
run: swift test -Xswiftc -warnings-as-errors -Xcc -Werror
24+
25+
test-ubuntu-latest:
26+
name: Test Swift ${{ matrix.swift }} Ubuntu Latest
27+
strategy:
28+
matrix:
29+
swift: ["6.0", "6.0.1", "6.0.2"]
30+
runs-on: ubuntu-latest
31+
container: swift:${{ matrix.swift }}
32+
steps:
33+
- uses: actions/checkout@v4
34+
- name: Run Tests
35+
run: swift test -Xswiftc -warnings-as-errors -Xcc -Werror

0 commit comments

Comments
 (0)