fix cloud job #125
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Lint & Test | |
on: | |
push: | |
branches: [ master ] | |
pull_request: | |
branches: [ master ] | |
jobs: | |
lint: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Set up Go | |
uses: actions/setup-go@v2 | |
with: | |
go-version: 1.22 | |
- name: golangci-lint | |
uses: golangci/golangci-lint-action@v2 | |
with: | |
skip-go-installation: true | |
args: --timeout 3m --verbose | |
test: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v2 | |
- name: Set up Go | |
uses: actions/setup-go@v2 | |
with: | |
go-version: 1.22 | |
- name: Collect dependencies | |
run: | | |
go mod download | |
go install gotest.tools/gotestsum@latest | |
- name: Run unit tests | |
run: gotestsum --junitfile unit-tests.xml -- -gcflags=-l ./... | |
- name: Test report | |
uses: dorny/test-reporter@v1 | |
if: success() || failure() | |
with: | |
name: Test report | |
path: unit-tests.xml | |
reporter: java-junit | |
fail-on-error: false |