29 lines
543 B
YAML
29 lines
543 B
YAML
on:
|
|
push:
|
|
branches:
|
|
- main
|
|
pull_request:
|
|
branches:
|
|
- main
|
|
|
|
name: Test
|
|
jobs:
|
|
test:
|
|
strategy:
|
|
matrix:
|
|
go-version: ["1.20.x"]
|
|
platform: [ubuntu-latest]
|
|
runs-on: ${{ matrix.platform }}
|
|
steps:
|
|
- name: Install Go
|
|
if: success()
|
|
uses: actions/setup-go@v2
|
|
with:
|
|
go-version: ${{ matrix.go-version }}
|
|
- name: Checkout code
|
|
uses: actions/checkout@v2
|
|
- name: Build
|
|
run: go build
|
|
- name: Run tests
|
|
run: go test ./... -v -covermode=count
|