Added isort config; linter now checks tests
Some checks failed
continuous-integration/drone the build failed
Some checks failed
continuous-integration/drone the build failed
This commit is contained in:
parent
cffc928d2f
commit
e044c07cd6
9 changed files with 19 additions and 11 deletions
8
Makefile
8
Makefile
|
|
@ -4,6 +4,7 @@ PYTHON := python3
|
|||
VENV := .venv
|
||||
# Minimum % coverage for tests to succeed
|
||||
MIN_COV := 50
|
||||
SRC := setup.py app tests
|
||||
|
||||
|
||||
# =====GENERAL=====
|
||||
|
|
@ -33,13 +34,14 @@ venv: $(VENV)/bin/activate
|
|||
## Formatting & linting
|
||||
### Format the codebase using black
|
||||
format: venv
|
||||
@ '$(VENV)'/bin/black setup.py app
|
||||
@ '$(VENV)'/bin/black $(SRC)
|
||||
@ '$(VENV)'/bin/isort $(SRC)
|
||||
.PHONY: format
|
||||
|
||||
### Lint using black & flake8
|
||||
lint: venv
|
||||
@ '$(VENV)'/bin/flake8 setup.py app
|
||||
@ '$(VENV)'/bin/black --check setup.py app
|
||||
@ '$(VENV)'/bin/flake8 $(SRC)
|
||||
@ '$(VENV)'/bin/black --check $(SRC)
|
||||
.PHONY: lint
|
||||
|
||||
|
||||
|
|
|
|||
Reference in a new issue