Skip to content

Commit

Permalink
Add regression build tag (#400)
Browse files Browse the repository at this point in the history
Signed-off-by: Ian Lewis <[email protected]>
  • Loading branch information
Ian Lewis authored Dec 15, 2022
1 parent 1dffc4b commit f439833
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 13 deletions.
12 changes: 1 addition & 11 deletions .github/workflows/pre-submit.cli.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,14 +36,4 @@ jobs:
- name: Run tests for verifier
run: |
set -euo pipefail
go mod vendor
# Build cli
go build -mod=vendor -o slsa-verifier ./cli/slsa-verifier/
# Builder service
go build -mod=vendor -o service ./cli/experimental/service/
# Tests
go test -mod=vendor -v -timeout=20m ./...
make regression-test
8 changes: 6 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -22,11 +22,15 @@ help: ## Shows all targets and help from the Makefile (this message).

.PHONY: unit-test
unit-test: ## Runs all unit tests.
# Run unit tests for the detect-workflow action.
make -C .github/actions/detect-workflow/ unit-test
go mod vendor
# NOTE: go test builds packages even if there are no tests.
go test -mod=vendor -v ./...

.PHONY: regression-test
regression-test: ## Runs all regression and unit tests.
go mod vendor
# NOTE: go test builds packages even if there are no tests.
go test -mod=vendor -tags=regression -v -timeout=20m ./...

## Linters
#####################################################################
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
//go:build regression

package main

import (
Expand Down

0 comments on commit f439833

Please sign in to comment.