Skip to content

Instantly share code, notes, and snippets.

@sergkondr
Last active September 4, 2023 14:49
Show Gist options
  • Save sergkondr/c3fa4fb07ebc3139ab790ac9ba9ad877 to your computer and use it in GitHub Desktop.
Save sergkondr/c3fa4fb07ebc3139ab790ac9ba9ad877 to your computer and use it in GitHub Desktop.
yp_run_tests
.PHONY: clear build test
APPS = server agent
BRANCH = $(shell git rev-parse --abbrev-ref HEAD)
test: build static-test ${BRANCH}-test clear
build:
for app in ${APPS}; do go build -buildvcs=false -o ./bin/$$app ./cmd/$$app; chmod +x ./bin/$$app; done
clear:
for app in ${APPS}; do rm ./bin/$$app; done
static-test:
go vet -vettool=./statictest ./...
iter1-test:
./metricstest -test.v -test.run='^TestIteration1$' -binary-path=bin/server
iter2-test:
./metricstest -test.v -test.run='^TestIteration2[AB]*$$' -source-path=. -agent-binary-path=bin/agent
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment