|
@@ -1,53 +1,55 @@
|
|
|
[tox]
|
|
|
-envlist = flake8,py{27,34,35,36,37},cov-report,cov-store
|
|
|
+skip_missing_interpreters=true
|
|
|
+envlist =
|
|
|
+ py{35,36,37},
|
|
|
+ flake8,
|
|
|
+ coverage_report
|
|
|
|
|
|
[testenv]
|
|
|
use_develop = true
|
|
|
deps =
|
|
|
- -r{toxinidir}/requirements-test.txt
|
|
|
+ -r{toxinidir}/requirements-dev.txt
|
|
|
# setup.py has unpinned dependencies by default
|
|
|
- !unpinned: -r{toxinidir}/requirements.txt
|
|
|
+ !unpinned: -r{toxinidir}/requirements-dev.txt
|
|
|
setenv =
|
|
|
COVERAGE_FILE = tests/.coverage.{envname}
|
|
|
PYTHONDONTWRITEBYTECODE=1
|
|
|
commands =
|
|
|
coverage run -m pytest {toxinidir}/tests {toxinidir}/flaskbb {posargs}
|
|
|
|
|
|
-[testenv:flake8]
|
|
|
-skip_install = true
|
|
|
-deps = -r{toxinidir}/requirements-lint.txt
|
|
|
-basepython=python3.6
|
|
|
-commands =
|
|
|
- flake8 --version
|
|
|
- flake8 --config={toxinidir}/tox.ini {toxinidir}/flaskbb {toxinidir}/tests
|
|
|
-
|
|
|
-[testenv:cov-report]
|
|
|
+[testenv:coverage_report]
|
|
|
skip_install = true
|
|
|
-setenv =
|
|
|
- COVERAGE_FILE = tests/.coverage
|
|
|
-deps =
|
|
|
- -r{toxinidir}/requirements-cov.txt
|
|
|
commands =
|
|
|
coverage combine tests
|
|
|
coverage report
|
|
|
|
|
|
-[testenv:cov-store]
|
|
|
+[testenv:codecov]
|
|
|
skip_install = true
|
|
|
-setenv =
|
|
|
- COVERAGE_FILE = tests/.coverage
|
|
|
-deps =
|
|
|
- -r{toxinidir}/requirements-cov.txt
|
|
|
+deps = codecov
|
|
|
commands =
|
|
|
- coverage html
|
|
|
-
|
|
|
+ coverage combine tests
|
|
|
+ coverage report
|
|
|
+ codecov
|
|
|
|
|
|
[testenv:black]
|
|
|
skip_install = true
|
|
|
deps = black
|
|
|
-basepython=python3.6
|
|
|
+basepython=python3.7
|
|
|
commands = black --check tests/ flaskbb/
|
|
|
|
|
|
+[testenv:flake8]
|
|
|
+skip_install = true
|
|
|
+basepython=python3.7
|
|
|
+commands =
|
|
|
+ flake8 --version
|
|
|
+ flake8 --config={toxinidir}/tox.ini {toxinidir}/flaskbb {toxinidir}/tests
|
|
|
+
|
|
|
[flake8]
|
|
|
+# B = bugbear
|
|
|
+# E = pycodestyle errors
|
|
|
+# F = flake8 pyflakes
|
|
|
+# W = pycodestyle warnings
|
|
|
+# B9 = bugbear opinions
|
|
|
ignore = E203, E712, E711, W503
|
|
|
select = C,E,F,W,B,B9
|
|
|
max-complexity = 10
|