diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index b58b80db..906d68b6 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -34,13 +34,7 @@ jobs: touch coverage.txt docker run --rm \ -v "$(pwd)/coverage.txt:/tmp/gobuild/coverage.txt" \ - test-container \ - go test \ - -race \ - -coverpkg=./... \ - -coverprofile=coverage.txt \ - -covermode=atomic \ - ./... + test-container - name: Code security analysis uses: snyk/actions/golang@master diff --git a/Dockerfile b/Dockerfile index 81439ca2..01be9e0e 100644 --- a/Dockerfile +++ b/Dockerfile @@ -17,6 +17,7 @@ FROM --platform=$BUILDPLATFORM base AS test # - we install g++ to support the race detector ENV CGO_ENABLED=1 RUN apk --update --no-cache add g++ +ENTRYPOINT go test -race -coverpkg=./... -coverprofile=coverage.txt -covermode=atomic ./... FROM --platform=$BUILDPLATFORM base AS lint ARG GOLANGCI_LINT_VERSION=v1.40.1