Have pre-commit run as part of running tests via tox

This commit is contained in:
Daniel Gallagher 2018-05-28 14:04:49 -07:00
parent e239e685f1
commit 3d5e293296
2 changed files with 4 additions and 2 deletions

View File

@ -4,12 +4,12 @@ REBUILD_FLAG =
all: venv test all: venv test
.PHONY: venv .PHONY: venv
venv: .venv.touch venv: .venv.touch install-hooks
tox -e venv $(REBUILD_FLAG) tox -e venv $(REBUILD_FLAG)
.PHONY: tests test .PHONY: tests test
tests: test tests: test
test: .venv.touch test: .venv.touch install-hooks
tox $(REBUILD_FLAG) tox $(REBUILD_FLAG)
.venv.touch: setup.py requirements-dev.txt .venv.touch: setup.py requirements-dev.txt

View File

@ -10,6 +10,8 @@ setenv =
PYTHONPATH = .:{envdir} PYTHONPATH = .:{envdir}
commands= commands=
py.test py.test
pre-commit install -f --install-hooks
pre-commit run --all-files
[testenv:pre-commit] [testenv:pre-commit]
basepython=python3.6 basepython=python3.6