File tree 4 files changed +24
-10
lines changed
4 files changed +24
-10
lines changed Original file line number Diff line number Diff line change @@ -19,6 +19,8 @@ matrix:
19
19
- env : TOXENV=py39-django31-drfmaster
20
20
21
21
include :
22
+ - python : 3.6
23
+ env : TOXENV=black
22
24
- python : 3.6
23
25
env : TOXENV=lint
24
26
- python : 3.6
Original file line number Diff line number Diff line change
1
+ black==20.8b1
1
2
flake8==3.8.4
2
3
flake8-isort==4.0.0
3
4
isort==5.6.4
Original file line number Diff line number Diff line change @@ -5,29 +5,34 @@ test = pytest
5
5
universal = 1
6
6
7
7
[flake8]
8
- ignore = F405,W504
9
- max-line-length = 100
8
+ max-line-length = 88
9
+ extend-ignore =
10
+ # whitespace before ':' - disabled as not PEP8 compliant
11
+ E203,
12
+ # line too long (managed by black)
13
+ E501,
14
+ # usage of star imports
15
+ # TODO mark star imports directly in code to ignore this error
16
+ F405
10
17
exclude =
11
- snapshots
12
18
build/lib,
13
- docs/conf.py,
14
- migrations,
15
19
.eggs
16
20
.tox,
17
21
env
18
22
.venv
19
23
20
24
[isort]
21
- indent = 4
25
+ multi_line_output = 3
26
+ include_trailing_comma = True
27
+ force_grid_wrap = 0
28
+ use_parentheses = True
29
+ ensure_newline_before_comments = True
30
+ line_length = 88
22
31
known_first_party = rest_framework_json_api
23
32
# This is to "trick" isort into putting example below DJA imports.
24
33
known_localfolder = example
25
- line_length = 100
26
- multi_line_output = 3
27
34
skip =
28
35
build/lib,
29
- docs/conf.py,
30
- migrations,
31
36
.eggs
32
37
.tox,
33
38
env
Original file line number Diff line number Diff line change @@ -20,6 +20,12 @@ setenv =
20
20
commands =
21
21
pytest --cov --no-cov-on-fail --cov-report xml {posargs}
22
22
23
+ [testenv:black]
24
+ basepython = python3.6
25
+ deps =
26
+ -rrequirements/requirements-codestyle.txt
27
+ commands = black --check .
28
+
23
29
[testenv:lint]
24
30
basepython = python3.6
25
31
deps =
You can’t perform that action at this time.
0 commit comments