github.com/whamcloud/lemur@v0.0.0-20190827193804-4655df8a52af/uat/Makefile (about) 1 ROOTDIR := $(dir $(shell dirname $(realpath $(lastword $(MAKEFILE_LIST))))) 2 GODOG_BIN := $(shell if which godog >/dev/null 2>&1; then true; else echo godog; fi) 3 PLUGINS := $(notdir $(shell ls -d $(ROOTDIR)/cmd/lhsm-plugin-*)) 4 TEST_BINARIES := lhsmd $(PLUGINS) 5 6 default: test 7 binaries: $(TEST_BINARIES) 8 9 $(TEST_BINARIES): 10 @echo -n "Building $@... " 11 @cd $(ROOTDIR)/cmd/$@ && \ 12 go install -race && \ 13 which $@ 14 15 $(GODOG_BIN): 16 @echo "You need to go get github.com/DATA-DOG/godog/cmd/godog" 17 exit 1 18 19 test: $(GODOG_BIN) 20 @echo Running User Acceptance Tests... 21 @tags=; if [ x"$(TAGS)" != "x" ]; then tags="--tags $(TAGS)"; fi; sudo -E sh -c "export PATH=$(PATH); $(shell which godog) --stop-on-failure $$tags ." 2>&1 | tee test.log