Skip to content

Commit

Permalink
Update tests/test_pylint_runners.py
Browse files Browse the repository at this point in the history
  • Loading branch information
Pierre-Sassoulas committed Nov 18, 2022
1 parent 82948a0 commit 7a8fe98
Showing 1 changed file with 4 additions and 7 deletions.
11 changes: 4 additions & 7 deletions tests/test_pylint_runners.py
Expand Up @@ -59,17 +59,14 @@ def test_runner_with_arguments(runner: _RunCallable, tmpdir: LocalPath) -> None:
assert err.value.code == 0


def test_pylint_argument_deduplication(tmpdir: LocalPath) -> None:
def test_pylint_argument_deduplication(tmpdir: LocalPath, tests_directory: Path) -> None:
"""Check that the Pylint runner does not over-report on duplicate
arguments.
(GitHub #6242, #4053).
See https://github.com/PyCQA/pylint/issues/6242 and
https://github.com/PyCQA/pylint/issues/4053
"""
filepath = str(
pathlib.Path(__file__)
.resolve()
.parent.joinpath("functional", "t", "too", "too_many_branches.py")
)
filepath = str(tests_directory / "functional/t/too/too_many_branches.py")
testargs = shlex.split("--report n --score n --max-branches 13")
testargs.extend([filepath] * 4)
exit_stack = contextlib.ExitStack()
Expand Down

0 comments on commit 7a8fe98

Please sign in to comment.