diff --git a/Makefile b/Makefile index 2942f60..5bbd22a 100644 --- a/Makefile +++ b/Makefile @@ -1,17 +1,14 @@ -REPORTER = dot +help: ## print this message + @grep -E '^[a-zA-Z_-]+:.*?## .*$$' $(MAKEFILE_LIST) | awk 'BEGIN {FS = ":.*?## "}; {printf "\033[36m%-20s\033[0m %s\n", $$1, $$2}' -test: +test: ## run tests either in the browser or in Node.js, based on the `BROWSERS` variable @if [ "x$(BROWSERS)" = "x" ]; then make test-node; else make test-zuul; fi -test-node: - @./node_modules/.bin/mocha \ - --reporter $(REPORTER) \ - --bail \ - test/index.js +test-node: ## run tests in Node.js + @./node_modules/.bin/mocha --reporter dot --bail test/index.js -test-zuul: - @./node_modules/zuul/bin/zuul \ - test/index.js +test-zuul: ## run tests in the browser + @./node_modules/zuul/bin/zuul test/index.js -.PHONY: test +.PHONY: help test test-node test-zuul