Skip to content

Commit

Permalink
Merge pull request #52 from AbcSxyZ/qa/pylint
Browse files Browse the repository at this point in the history
configure pylint for tests
  • Loading branch information
patricklodder authored Dec 18, 2021
2 parents 334736d + b3a0aef commit 95135b3
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 2 deletions.
10 changes: 8 additions & 2 deletions .github/workflows/lint-py.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,5 +24,11 @@ jobs:
- name: Checkout
uses: actions/checkout@v2

- name: Run linter
run: find . -name "*.py" | xargs pylint
- name: Run linter for images code
run: find . -name "*.py" ! -path "*/tests/*" | xargs pylint

- name: Install pylint dependencies for tests
run: pip3 install pytest

- name: Run linter for tests code
run: find "./tests" -name "*.py" | xargs pylint --rcfile=pylintrc.tests
7 changes: 7 additions & 0 deletions pylintrc.tests
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
[tests-configuration]
disable = duplicate-code, # Tests having similar code
no-member, # pytest global variables in conftest.py not detected
consider-using-with, # conftest temporary directory would need a with
import-error # EntrypointHook unable to import entrypoint


0 comments on commit 95135b3

Please sign in to comment.