Skip to content

Commit a382366

Browse files
committed
Add working Linux tests
1 parent ebd2ea4 commit a382366

File tree

1 file changed

+23
-8
lines changed

1 file changed

+23
-8
lines changed

.github/workflows/build.yml

Lines changed: 23 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -8,22 +8,37 @@ on:
88
branches: [ master ]
99
paths-ignore: [ README.md ]
1010
jobs:
11-
build:
12-
name: Build and test on ${{ matrix.os }}
13-
runs-on: ${{ matrix.os }}
14-
strategy:
15-
matrix:
16-
os: [macos-10.15, macos-latest, ubuntu-18.04, ubuntu-20.04]
11+
macos:
12+
name: Build and test on macos-latest
13+
runs-on: macOS-latest
1714
steps:
1815
- uses: actions/checkout@v2
19-
- name: Set code coverage path
16+
- name: Set code coverage path
2017
run: echo "codecov_path=$(swift test --show-codecov-path)" >> $GITHUB_ENV
2118
- name: Test and publish code coverage to Code Climate
2219
uses: paulofaria/codeclimate-action@master
23-
if: matrix.os == 'macos-10.15'
2420
env:
2521
CC_TEST_REPORTER_ID: ${{secrets.CC_TEST_REPORTER_ID}}
2622
with:
2723
downloadUrl: https://github.com/paulofaria/test-reporter/releases/download/0.9.0/test-reporter-0.9.0-darwin-amd64
2824
coverageCommand: swift test --enable-test-discovery --enable-code-coverage
2925
coverageLocations: ${{ env.codecov_path }}:lcov-json
26+
27+
linux:
28+
name: Build and test on ${{ matrix.tag }}-${{ matrix.os }}
29+
runs-on: ubuntu-latest
30+
strategy:
31+
matrix:
32+
os:
33+
- focal
34+
- bionic
35+
tag:
36+
- swift:5.3
37+
- swift:5.4
38+
container:
39+
image: ${{ matrix.tag }}-${{ matrix.os }}
40+
steps:
41+
- name: Checkout
42+
uses: actions/checkout@v2
43+
- name: Test
44+
run: swift test --enable-test-discovery --enable-code-coverage --sanitize=thread

0 commit comments

Comments
 (0)