summaryrefslogtreecommitdiff
path: root/tests/extensions/test_overlapping_exceptions.py
diff options
context:
space:
mode:
authorDaniƫl van Noord <13665637+DanielNoord@users.noreply.github.com>2021-09-04 18:52:55 +0200
committerGitHub <noreply@github.com>2021-09-04 18:52:55 +0200
commit25000863761220c1aa5db129e3cd41f5fe51b167 (patch)
treed211e4464a8aef25f969adffe7ba7cb6df8b8981 /tests/extensions/test_overlapping_exceptions.py
parent6c818310fd0e2396b6333ad623da577bf84e361e (diff)
downloadpylint-git-25000863761220c1aa5db129e3cd41f5fe51b167.tar.gz
Add typing with `PyAnnotate` to `./tests` (#4950)
* Add mypy_extensions to requirement for ``NoReturn`` Co-authored-by: Pierre Sassoulas <pierre.sassoulas@gmail.com>
Diffstat (limited to 'tests/extensions/test_overlapping_exceptions.py')
-rw-r--r--tests/extensions/test_overlapping_exceptions.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/tests/extensions/test_overlapping_exceptions.py b/tests/extensions/test_overlapping_exceptions.py
index 34a5be99a..005e0bcf9 100644
--- a/tests/extensions/test_overlapping_exceptions.py
+++ b/tests/extensions/test_overlapping_exceptions.py
@@ -9,6 +9,7 @@ from os.path import dirname, join
import pytest
from pylint.extensions.overlapping_exceptions import OverlappingExceptionsChecker
+from pylint.lint.pylinter import PyLinter
@pytest.fixture(scope="module")
@@ -21,7 +22,7 @@ def disable():
return ["I"]
-def test_overlapping_exceptions(linter):
+def test_overlapping_exceptions(linter: PyLinter) -> None:
test = join(dirname(__file__), "data", "overlapping_exceptions.py")
linter.check([test])
msgs = linter.reporter.messages
@@ -64,7 +65,7 @@ def test_overlapping_exceptions(linter):
assert (msg.line, msg.msg) == exp
-def test_overlapping_exceptions_py33(linter):
+def test_overlapping_exceptions_py33(linter: PyLinter) -> None:
"""From Python 3.3 both IOError and socket.error are aliases for OSError."""
test = join(dirname(__file__), "data", "overlapping_exceptions_py33.py")
linter.check([test])