-
Notifications
You must be signed in to change notification settings - Fork 2
/
Makefile
28 lines (23 loc) · 662 Bytes
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
test: lint
@NODE_ENV=test ./node_modules/.bin/mocha $(MOCHA_OPTS) test/*Spec.js
lint:
@ find . -name "*.js" \
-not -path "./node_modules/*" \
-not -path "./coverage/*" -print0 | \
xargs -0 ./node_modules/eslint/bin/eslint.js
test-cov: lint
@NODE_ENV=test node $(MOCHA_OPTS) \
node_modules/.bin/istanbul cover \
./node_modules/.bin/_mocha \
-- -u exports \
test/*Spec.js
open-cov:
open coverage/lcov-report/index.html
test-travis: lint
@NODE_ENV=test node $(MOCHA_OPTS) \
./node_modules/.bin/istanbul cover \
./node_modules/.bin/_mocha \
--report lcovonly \
-- -u exports \
--bail
.PHONY: test lint test-cov open-cov test-travis