-
-
Notifications
You must be signed in to change notification settings - Fork 101
/
tox.ini
104 lines (99 loc) · 1.94 KB
/
tox.ini
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
[tox]
envlist = py37, py38, py39
skipsdist = True
toxworkdir=.tox-mobsf
[testenv]
passenv = *
deps =
.
pytest
commands =
py.test -vv --cache-clear tests
setenv =
SEMGREP_R2C_INTERNAL_EXPLICIT_SEMGREPIGNORE = ./tests/assets/src/.semgrepignore
[testenv:lint]
skip_install = true
deps =
pydocstyle
autopep8
flake8
flake8-broken-line
flake8-bugbear
flake8-builtins
flake8-colors
flake8-commas
flake8-comprehensions
flake8-docstrings
flake8-eradicate
flake8-import-order
flake8-logging-format
flake8-quotes
flake8-self
pep8-naming
radon
commands =
autopep8 --recursive --in-place setup.py mobsfscan tests
flake8 setup.py mobsfscan tests
[testenv:bandit]
skip_install = true
deps =
bandit
commands =
bandit mobsfscan -r
[testenv:publish]
skip_install = true
deps =
twine
wheel
commands =
python setup.py sdist bdist_wheel
twine upload dist/*
[testenv:clean]
deps =
skip_install = true
allowlist_externals =
bash
find
rm
commands =
find . -name "*.py[co]" -delete
bash -c 'find . -name "__pycache__" -exec rm -fr \{\} \; -prune'
bash -c 'find . -depth -name "*.egg-info" -exec rm -fr \{\} \;'
;rm -rf .tox-mobsf
rm -rf .pytest_cache
rm -rf build
rm -rf dist
; Reference for error codes:
; http://www.pydocstyle.org/en/latest/error_codes.html
[flake8]
enable-extensions = G
exclude =
.tox-mobsf
.git
__pycache__
build
dist
venv
ignore =
D101,
# Missing docstring in public class
D103,
# Missing docstring in public function
D104,
# Missing docstring
D107,
# docstring is not mandatory
D401,
# Allow non imperative mood
W503,
# Allow line break before binary operator
Q003,
# Allow only ' for strings
I100,
# Use python sort imports
SF01,
# Allow Private member access
R701,
# Too complex
radon_max_cc = 10
max-line-length = 88