diff options
author | Pierre Sassoulas <pierre.sassoulas@gmail.com> | 2021-10-27 11:19:39 +0200 |
---|---|---|
committer | Pierre Sassoulas <pierre.sassoulas@gmail.com> | 2021-10-27 11:20:16 +0200 |
commit | 04f61cf7c47159f4d99e72246dac9116f5b99586 (patch) | |
tree | 5f98ab751d28a9a43a2674abb15ded8bdf3111da | |
parent | 01dafd9a04cda2082c83f58af2cb3416bbc79ab9 (diff) | |
download | pylint-git-checker-check-deprecation.tar.gz |
Add a test for Pylinter.check() deprecationchecker-check-deprecation
-rw-r--r-- | tests/lint/test_pylinter.py | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/tests/lint/test_pylinter.py b/tests/lint/test_pylinter.py index 27fc10ebf..900d53fb3 100644 --- a/tests/lint/test_pylinter.py +++ b/tests/lint/test_pylinter.py @@ -35,3 +35,9 @@ def test_crash_in_file( with open(files[0], encoding="utf8") as f: content = f.read() assert "Failed to import module spam." in content + + +def test_check_deprecation(linter: PyLinter, recwarn): + linter.check("myfile.py") + msg = recwarn.pop() + assert "check function will only accept sequence" in str(msg) |