Switched to Black-focused config
This commit is contained in:
parent
e044c07cd6
commit
11e5ee2869
10 changed files with 21 additions and 16 deletions
7
Makefile
7
Makefile
|
|
@ -4,7 +4,7 @@ PYTHON := python3
|
|||
VENV := .venv
|
||||
# Minimum % coverage for tests to succeed
|
||||
MIN_COV := 50
|
||||
SRC := setup.py app tests
|
||||
SRC := setup.py config_skeleton tests
|
||||
|
||||
|
||||
# =====GENERAL=====
|
||||
|
|
@ -34,18 +34,19 @@ venv: $(VENV)/bin/activate
|
|||
## Formatting & linting
|
||||
### Format the codebase using black
|
||||
format: venv
|
||||
@ '$(VENV)'/bin/black $(SRC)
|
||||
@ '$(VENV)'/bin/isort $(SRC)
|
||||
@ '$(VENV)'/bin/black $(SRC)
|
||||
.PHONY: format
|
||||
|
||||
### Lint using black & flake8
|
||||
lint: venv
|
||||
@ '$(VENV)'/bin/flake8 $(SRC)
|
||||
@ '$(VENV)'/bin/black --check $(SRC)
|
||||
@ '$(VENV)'/bin/isort --check $(SRC)
|
||||
.PHONY: lint
|
||||
|
||||
|
||||
## Testing
|
||||
test: venv
|
||||
@ '$(VENV)'/bin/pytest --cov=app --cov-fail-under='$(MIN_COV)' tests/
|
||||
@ '$(VENV)'/bin/pytest --cov=config_skeleton --cov-fail-under='$(MIN_COV)' tests/
|
||||
.PHONY: test
|
||||
|
|
|
|||
Reference in a new issue