2021-09-04 00:51:02 -04:00
|
|
|
name: Run Tests
|
|
|
|
|
2021-09-04 00:18:12 -04:00
|
|
|
on:
|
|
|
|
push:
|
|
|
|
branches:
|
|
|
|
- master
|
2021-11-03 09:40:22 -04:00
|
|
|
paths-ignore:
|
2022-04-18 08:45:07 -04:00
|
|
|
- ".github/workflows/codeql-analysis.yml"
|
2021-11-03 09:40:22 -04:00
|
|
|
- ".github/workflows/test-on-pr.yml"
|
2023-05-08 00:48:50 -04:00
|
|
|
- ".github/workflows/contributors.yml"
|
2023-10-26 11:29:20 -04:00
|
|
|
- ".github/workflows/sync.yml"
|
2023-11-28 10:18:29 -05:00
|
|
|
- ".github/workflows/release.yml"
|
2021-11-03 09:40:22 -04:00
|
|
|
- "README.md"
|
|
|
|
- ".goreleaser.yml"
|
|
|
|
|
2021-09-04 00:18:12 -04:00
|
|
|
jobs:
|
|
|
|
tests:
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
env:
|
|
|
|
GO111MODULE: on
|
|
|
|
steps:
|
2023-10-21 06:27:25 -04:00
|
|
|
- uses: actions/checkout@v4
|
2023-05-10 12:08:54 -04:00
|
|
|
- uses: actions/setup-go@v4
|
2021-11-04 00:55:12 -04:00
|
|
|
with:
|
2023-10-21 06:27:25 -04:00
|
|
|
go-version: "^1.21.3"
|
2021-09-04 00:18:12 -04:00
|
|
|
- name: Unit test
|
|
|
|
run: |
|
|
|
|
go test -v ./...
|
2021-09-04 00:19:59 -04:00
|
|
|
- name: Build test
|
|
|
|
run: |
|
|
|
|
go build cmd/dashboard/main.go
|
2021-09-04 00:18:12 -04:00
|
|
|
- name: Run Gosec Security Scanner
|
2023-10-21 06:27:25 -04:00
|
|
|
uses: securego/gosec@master
|
|
|
|
with:
|
2023-10-21 10:21:21 -04:00
|
|
|
args: --exclude=G104,G402 ./...
|