Skip to content

Commit 229c894

Browse files
committed
Add Flake8
1 parent e6a0b48 commit 229c894

File tree

5 files changed

+34
-41
lines changed

5 files changed

+34
-41
lines changed

.github/workflows/flake8.yml

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
# https://github.com/marketplace/actions/flake8-annotate-action
2+
3+
name: Flake8 Lint
4+
"on": ["push"]
5+
6+
jobs:
7+
flake8:
8+
name: Flake8 tests
9+
runs-on: ubuntu-latest
10+
steps:
11+
- uses: actions/checkout@master
12+
- uses: gijswobben/flake8-action@main
13+
with:
14+
strict: true
15+
strict_for: "E501"
16+
not_strict_for: "E502,E503"
17+
message_title: "Flake8 error found"
18+
flake8_config: |
19+
[flake8]
20+
exclude = examples/ tests/
21+
max-line-length = 120
22+
extend-ignore =
23+
# See https://github.com/PyCQA/pycodestyle/issues/373
24+
E203,
25+
additional_packages: pep8-naming==0.13.2 flake8-annotations==2.9.1 darglint==1.8.1 flake8-bugbear==22.10.27

.github/workflows/python-package.yml

Lines changed: 0 additions & 40 deletions
This file was deleted.
10.5 KB
Binary file not shown.

pyproject.toml

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,4 +21,11 @@ exclude = '''
2121
| venv
2222
| test/resources
2323
)/
24-
'''
24+
'''
25+
26+
[tool.pytest.ini_options]
27+
minversion = "6.0"
28+
addopts = "-ra -q"
29+
testpaths = [
30+
"tests"
31+
]

tests/__init__.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+

0 commit comments

Comments
 (0)