diff options
author | Daniël van Noord <13665637+DanielNoord@users.noreply.github.com> | 2021-09-29 14:33:29 +0200 |
---|---|---|
committer | Daniël van Noord <13665637+DanielNoord@users.noreply.github.com> | 2021-09-29 20:29:37 +0200 |
commit | 8c74530e677ad2e8332f5ab0e7e64516571aae40 (patch) | |
tree | 0f272a4bc8d294855938b31607c81b7cc0559673 /tests | |
parent | 118c91972562058d85d09cb64537b8c383556790 (diff) | |
download | pylint-git-8c74530e677ad2e8332f5ab0e7e64516571aae40.tar.gz |
Fix empty regex options not converting to regex
Diffstat (limited to 'tests')
-rw-r--r-- | tests/extensions/test_check_docs.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/tests/extensions/test_check_docs.py b/tests/extensions/test_check_docs.py index 65d077aed..1c250bc9b 100644 --- a/tests/extensions/test_check_docs.py +++ b/tests/extensions/test_check_docs.py @@ -25,6 +25,8 @@ in particular the parameter documentation checker `DocstringChecker` # pylint: disable=too-many-public-methods +import re + import astroid import pytest from astroid import nodes @@ -2325,7 +2327,7 @@ class TestParamDocChecker(CheckerTestCase): ): self.checker.visit_functiondef(node) - @set_config_directly(no_docstring_rgx=r"^_(?!_).*$") + @set_config_directly(no_docstring_rgx=re.compile(r"^_(?!_).*$")) def test_skip_no_docstring_rgx(self) -> None: """Example of a function that matches the default 'no-docstring-rgx' config option |