-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
38 lines (28 loc) · 866 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
ifneq ($(shell which python3),)
PYTHON3 ?= python3
else
PYTHON3 ?= python
endif
all: doc setup
doc:
epydoc --config epydoc.conf
setup:
rm -rf work
${PYTHON3} createexample.py
clean:
rm -rf html work
rm -f *.pyc *~ dokuforge/*.pyc .coverage
check: test
# entire test suite
test: test.py
${PYTHON3} test.py
# only test exporting of text (microtypography, titles etc.)
test-exported-strings:
${PYTHON3} test.py DokuforgeParserUnitTests DokuforgeMicrotypeUnitTests DokuforgeTitleParserTests DokuforgeCaptionParserTests
test-exporter: test-exported-strings
${PYTHON3} test.py DokuforgeExporterTests LocalExportScriptTest
.coverage:$(wildcard dokuforge/*.py) test.py
${PYTHON3} -m coverage run --include=dokuforge/*.py,test.py ./test.py
coverage: .coverage
${PYTHON3} -m coverage report -m test.py dokuforge/*.py
.PHONY: all doc clean setup test check