不要怂,就是干,撸起袖子干!

Commit 305a45a7 by Sascha Depold

restructured the makefile + added spec teaser

1 parent 11a2f7fb
Showing with 27 additions and 22 deletions
REPORTER ?= dot REPORTER ?= dot
TESTS = $(shell find ./test/* -name "*.test.js") TESTS = $(shell find ./test/* -name "*.test.js")
sqlite:
@DIALECT=sqlite ./node_modules/mocha/bin/mocha \
--colors \
--reporter $(REPORTER) \
$(TESTS)
mysql: # test commands
@DIALECT=mysql ./node_modules/mocha/bin/mocha \
--colors \
--reporter $(REPORTER) \
$(TESTS)
postgres: teaser:
@DIALECT=postgres ./node_modules/mocha/bin/mocha \ echo "" && \
--colors \ node -pe "Array(20 + '$(DIALECT)'.length + 3).join('#')" && \
--reporter $(REPORTER) \ echo '# Running tests for $(DIALECT) #' && \
$(TESTS) node -pe "Array(20 + '$(DIALECT)'.length + 3).join('#')" && \
echo ''
pgsql: postgres test:
make teaser && \
./node_modules/mocha/bin/mocha \
--colors \
--reporter $(REPORTER) \
$(TESTS)
sqlite:
@DIALECT=sqlite make test
mysql:
@DIALECT=mysql make test
postgres:
@DIALECT=postgres make test
postgres-native: postgres-native:
@DIALECT=postgres-native ./node_modules/mocha/bin/mocha \ @DIALECT=postgres-native make test
--colors \
--reporter $(REPORTER) \ # test aliases
$(TESTS)
pgsql: postgres
postgresn: postgres-native postgresn: postgres-native
all: make sqlite && make mysql && make postgres && make postgres-native # test all the dialects \o/
all: sqlite mysql postgres postgres-native
.PHONY: sqlite mysql postgres pgsql postgres-native postgresn all .PHONY: sqlite mysql postgres pgsql postgres-native postgresn all test
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!