Update makefile.

This commit is contained in:
Jonathan Zernik 2020-02-22 19:59:29 -08:00
parent cea55d63bd
commit b477d6e378
4 changed files with 69 additions and 0 deletions

2
.gitignore vendored
View file

@ -12,3 +12,5 @@ build/
.idea/
*.swp
*~
.tox/
.mypy_cache/

17
Makefile Normal file
View file

@ -0,0 +1,17 @@
all: test
clean:
rm -rf build dist *.egg-info/ .tox/ target/ venv/
find . -name '*.pyc' -delete
find . -name '__pycache__' -delete
test:
tox
coverage:
tox -e coverage
mypy:
tox -e mypy
.PHONY: all clean test coverage mypy

1
requirements.txt Normal file
View file

@ -0,0 +1 @@
flask==1.1.1

49
tox.ini Normal file
View file

@ -0,0 +1,49 @@
[tox]
envlist = py37
[testenv]
deps =
pytest
-rrequirements.txt
commands =
py.test {posargs:tests}
[testenv:coverage]
deps =
{[testenv]deps}
coverage
pytest
commands = coverage run -m pytest {posargs:tests}
[testenv:mypy]
deps =
{[testenv]deps}
mypy
mypy_paths =
squeakserver
tests
commands =
mypy --ignore-missing-imports {posargs:{[testenv:mypy]mypy_paths}}
[testenv:codechecks]
basepython = python3.7
deps =
flake8
reorder-python-imports
codechecks_paths =
squeakserver
tests
commands =
flake8
reorder-python-imports
[testenv:run]
deps =
-rrequirements.txt
setenv =
FLASK_APP=squeakserver
FLASK_ENV=development
commands =
flask init-db
flask run