Added test and test_local targets to the Makefile.
This commit is contained in:
parent
a58d99325a
commit
450b0ab671
20
Makefile
20
Makefile
|
|
@ -1,14 +1,32 @@
|
|||
#!/usr/bin/make
|
||||
PY_COV=python3-coverage
|
||||
|
||||
|
||||
deb:
|
||||
fakeroot dpkg-buildpackage -uc -b
|
||||
|
||||
lint:
|
||||
# flake8 --filename is broken
|
||||
ln -sf src/kiplot kiplot.py
|
||||
# stop the build if there are Python syntax errors or undefined names
|
||||
flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics
|
||||
flake8 . --count --statistics
|
||||
rm kiplot.py
|
||||
|
||||
test: lint
|
||||
$(PY_COV) erase
|
||||
pytest-3
|
||||
$(PY_COV) report
|
||||
|
||||
test_local: lint
|
||||
rm -rf output
|
||||
$(PY_COV) erase
|
||||
pytest-3 --plot_dir output
|
||||
$(PY_COV) report
|
||||
$(PY_COV) html
|
||||
x-www-browser htmlcov/index.html
|
||||
|
||||
deb_clean:
|
||||
fakeroot debian/rules clean
|
||||
|
||||
.PHONY: deb deb_clean
|
||||
.PHONY: deb deb_clean lint test test_local
|
||||
|
|
|
|||
Loading…
Reference in New Issue