-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathMakefile
42 lines (34 loc) · 907 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
29
30
31
32
33
34
35
36
37
38
39
40
41
42
test: lib test/lib node_modules
TEST_LIB_PATH="../../lib" ./node_modules/.bin/mocha \
--recursive \
--reporter dot \
--check-leaks \
--ui tdd
test-coveralls: build/lib-coverage test/lib node_modules
TEST_LIB_PATH="../../build/lib-coverage" ./node_modules/.bin/mocha \
--recursive \
--reporter mocha-lcov-reporter \
--ui tdd | \
./node_modules/coveralls/bin/coveralls.js
test-cov: build/coverage.html
build/coverage.html: build/lib-coverage test/lib node_modules
TEST_LIB_PATH="../../build/lib-coverage" ./node_modules/.bin/mocha \
--recursive \
--reporter html-cov \
--ui tdd \
> $@
build/lib-coverage: build lib node_modules
./node_modules/.bin/jscoverage \
--no-highlight \
lib \
build/lib-coverage
node_modules: package.json
npm install
touch $@
build:
if [ ! -d $@ ]; then \
mkdir $@; \
fi;
clean:
rm -rf build
.PHONY: test test-cov test-coveralls clean