-
Notifications
You must be signed in to change notification settings - Fork 6
/
Makefile
25 lines (21 loc) · 758 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
.PHONY: all
all: test lint type_check
.PHONY: test
test:
PYTHONPATH=src python -m pytest --cov=src/ --no-cov-on-fail $(PYTEST_ARGS) tests/
.PHONY: lint
lint:
PYTHONPATH=src python -m pylint src/ tests/
.PHONY: type_check
type_check:
PYTHONPATH=src mypy --show-error-codes --check-untyped-defs --ignore-missing-imports src/ tests/
# explicitly update .txt after changing .in:
# make -W test-requirements.{in,txt} PIP_COMPILE_ARGS="-q"
# upgrade all deps:
# make -W test-requirements.{in,txt} PIP_COMPILE_ARGS="-U"
# upgrade specific deps:
# make -W test-requirements.{in,txt} PIP_COMPILE_ARGS="-P foo"
ifneq ($(PIP_COMPILE_ARGS),)
test-requirements.txt: setup.py test-requirements.in
pip-compile -q $(PIP_COMPILE_ARGS) --output-file $@ $^
endif