Skip to content

Remove /types and /utils #6

Remove /types and /utils

Remove /types and /utils #6

Workflow file for this run

name: PKG Build and Test
on: [push]
jobs:
build-test:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4
- name: Set up Go
uses: actions/setup-go@0c52d547c9bc32b1aa3301fd7a9cb496313a4491 # v5.0.0
with:
go-version-file: "go.mod"
- name: Build
run: go build -v ./...
- name: Unit Tests
run: GORACE="log_path=$PWD/race" go test -race ./... -coverpkg=./... -coverprofile=coverage.txt
- name: Print Races
if: failure()
id: print-races
run: |
find race.* | xargs cat > race.txt
if [[ -s race.txt ]]; then
cat race.txt
fi
- name: Upload Go test results
if: always()
uses: actions/upload-artifact@65462800fd760344b1a7b4382951275a0abb4808 # v4.3.3
with:
name: go-test-results
path: |
./coverage.txt
./race.*
check-tidy:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4
- name: Set up Go
uses: actions/setup-go@0c52d547c9bc32b1aa3301fd7a9cb496313a4491 # v5.0.0
with:
go-version-file: "go.mod"
- name: Ensure "make gomodtidy" has been run
run: |
make gomodtidy
git add --all
git diff --minimal --cached --exit-code
- name: Ensure "make generate" has been run
run: |
make rm-mocked
make generate
git add --all
git diff --stat --cached --exit-code