mirror of
https://github.com/mjl-/mox.git
synced 2024-12-26 16:33:47 +03:00
add github workflow to build & test, exporting a coverage file
This commit is contained in:
parent
dcc051e149
commit
d18983d9a6
1 changed files with 22 additions and 0 deletions
22
.github/workflows/build-test.yml
vendored
Normal file
22
.github/workflows/build-test.yml
vendored
Normal file
|
@ -0,0 +1,22 @@
|
||||||
|
name: Build and test
|
||||||
|
|
||||||
|
on: [push, pull_request, workflow_dispatch]
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
build-test:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
strategy:
|
||||||
|
max-parallel: 1 # cannot run tests concurrently, files are created
|
||||||
|
matrix:
|
||||||
|
go-version: ['stable', 'oldstable']
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v3
|
||||||
|
- uses: actions/setup-go@v4
|
||||||
|
with:
|
||||||
|
go-version: ${{ matrix.go-version }}
|
||||||
|
- run: make build
|
||||||
|
# Need to run tests with a temp dir on same file system for os.Rename to succeed.
|
||||||
|
- run: 'mkdir -p tmp && TMPDIR=$PWD/tmp make test'
|
||||||
|
- uses: actions/upload-artifact@v3
|
||||||
|
with:
|
||||||
|
path: cover.html
|
Loading…
Reference in a new issue