generated from mattrobmattrob/bazel-ios-swiftui-template
-
Notifications
You must be signed in to change notification settings - Fork 3
39 lines (36 loc) · 960 Bytes
/
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
name: Tests
on:
pull_request:
push:
branches:
- main
# One active job per PR, cancel older ones on push
concurrency:
group: ${{ github.head_ref || github.run_id }}
cancel-in-progress: true
jobs:
tests:
strategy:
matrix:
bzlmod: ["--enable_bzlmod", "--noenable_bzlmod"]
name: Build and Test
runs-on: macos-14
steps:
- uses: actions/checkout@v3
- name: Select Xcode
run: .github/workflows/xcode_select.sh
- name: Lint
run: bazelisk run :lint && git diff --exit-code
- name: Build and Test
run: |
# Run the tests
bazelisk test --local_test_jobs=1 ${{ matrix.bzlmod }} -- //...
- name: Generate Xcode Project
run: |
# Generate Xcode project
bazelisk run -- //:xcodeproj
- uses: actions/upload-artifact@v2
if: failure()
with:
name: bazel-testlogs
path: bazel-testlogs