Skip to content

Commit 89d7611

Browse files
authored
Update tox.ini
Ignore flake8 E704 (Multiple statements on one line) too make overloads smaller Add [pytest] config section
1 parent 4f9ef1f commit 89d7611

File tree

1 file changed

+26
-2
lines changed

1 file changed

+26
-2
lines changed

tox.ini

Lines changed: 26 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ commands = coverage run --omit="git/test/*" -m unittest --buffer {posargs}
1212
coverage report
1313

1414
[testenv:flake8]
15-
commands = flake8 --ignore=W293,E265,E266,W503,W504,E731 {posargs}
15+
commands = flake8 --ignore=W293,E265,E266,W503,W504,E704,E731 {posargs}
1616

1717
[testenv:type]
1818
description = type check ourselves
@@ -32,6 +32,30 @@ commands = {posargs}
3232
# E731 = do not assign a lambda expression, use a def
3333
# W293 = Blank line contains whitespace
3434
# W504 = Line break after operator
35-
ignore = E265,W293,E266,E731, W504
35+
# E707 = multiple statements in one line - used for @overloads
36+
ignore = E265,W293,E266,E731,E704, W504
3637
max-line-length = 120
3738
exclude = .tox,.venv,build,dist,doc,git/ext/
39+
40+
[pytest]
41+
python_files =
42+
test_*.py
43+
44+
# space seperated list of paths from root e.g test tests doc/testing
45+
testpaths = test
46+
47+
# --cov coverage
48+
# --cov-report term # send report to terminal term-missing -> terminal with line numbers html xml
49+
# --cov-report term-missing # to terminal with line numbers
50+
# --cov-report html:path # html file at path
51+
# --maxfail # number of errors before giving up
52+
# -disable-warnings # Disable pytest warnings (not codebase warnings)
53+
#-rf # increased reporting of failures
54+
# -rE # increased reporting of errors
55+
# --ignore-glob=**/gitdb/* # ignore glob paths
56+
addopts = --cov=git --cov-report=term --maxfail=50 -rf --verbosity=0 --disable-warnings
57+
58+
# ignore::WarningType # ignores those warnings
59+
# error # turn any unignored warning into errors
60+
filterwarnings =
61+
ignore::DeprecationWarning

0 commit comments

Comments
 (0)