1
0
Fork 0
mirror of https://github.com/Luzifer/go_helpers.git synced 2024-10-18 06:14:21 +00:00

Add test as Github workflow

Signed-off-by: Knut Ahlers <knut@ahlers.me>
This commit is contained in:
Knut Ahlers 2023-01-28 18:45:36 +01:00
parent 36c4490cff
commit 2afb800b7a
Signed by: luzifer
GPG key ID: D91C3E91E4CAD6F5

34
.github/workflows/test.yml vendored Normal file
View file

@ -0,0 +1,34 @@
---
name: test-and-build
on: [push]
jobs:
test:
strategy:
fail-fast: false
matrix:
go_version:
- '1.18'
- '1.19'
- 'latest'
defaults:
run:
shell: sh
container:
image: golang:${{ matrix.go_version }}
env:
CGO_ENABLED: 0
GOPATH: /go
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Test code
run: go test -v -cover ./...
...