2021-09-04 00:51:02 -04:00
|
|
|
name: Run Tests on PR
|
|
|
|
|
|
|
|
on:
|
|
|
|
pull_request:
|
|
|
|
branches:
|
|
|
|
- master
|
|
|
|
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:51:02 -04:00
|
|
|
- name: Unit test
|
|
|
|
run: |
|
|
|
|
go test -v ./...
|
|
|
|
- name: Build test
|
|
|
|
run: |
|
|
|
|
go build cmd/dashboard/main.go
|
|
|
|
- name: Run Gosec Security Scanner
|
2023-10-21 06:27:25 -04:00
|
|
|
uses: securego/gosec@master
|
|
|
|
with:
|
|
|
|
args: --exclude=G104 ./...
|