diff --git a/.github/workflows/pr.yaml b/.github/workflows/pr.yaml index d495d48..3f4383c 100644 --- a/.github/workflows/pr.yaml +++ b/.github/workflows/pr.yaml @@ -15,4 +15,4 @@ jobs: - name: Run unit tests run: | - pwd && ls -ltr && go version && go test ./... -cover \ No newline at end of file + pwd && ls -ltr && go version && make test \ No newline at end of file diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 45c1ed3..9ed48e1 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -52,7 +52,7 @@ jobs: - name: Run unit tests run: | - go test ./... -cover + make test - name: GoReleaser uses: goreleaser/goreleaser-action@v4.2.0 diff --git a/Makefile b/Makefile index 66eae56..fef1b82 100644 --- a/Makefile +++ b/Makefile @@ -1,7 +1,10 @@ .PHONY: lambda - lambda: mkdir -p functions CGO_ENABLED=0 GOOS=linux go build --ldflags "-s -w" -o functions/github-action-webhook cmd/webhook/main.go -all: lambda \ No newline at end of file +all: lambda + +.PHONY: test +test: + go test ./... -cover \ No newline at end of file