Skip to content

Commit 01c7f93

Browse files
Remove PyPy special case, typing fixes
1 parent 3092b42 commit 01c7f93

File tree

1 file changed

+2
-7
lines changed

1 file changed

+2
-7
lines changed

pylint/testutils/lint_module_test.py

+2-7
Original file line numberDiff line numberDiff line change
@@ -11,15 +11,13 @@
1111
from collections import Counter
1212
from io import StringIO
1313
from pathlib import Path
14-
from typing import Counter as CounterType
15-
from typing import TextIO, Tuple
14+
from typing import TextIO
1615

1716
import pytest
1817
from _pytest.config import Config
1918

2019
from pylint import checkers
2120
from pylint.config.config_initialization import _config_initialization
22-
from pylint.constants import IS_PYPY
2321
from pylint.lint import PyLinter
2422
from pylint.message.message import Message
2523
from pylint.testutils.constants import _EXPECTED_RE, _OPERATORS, UPDATE_OPTION
@@ -33,7 +31,7 @@
3331
from pylint.testutils.output_line import OutputLine
3432
from pylint.testutils.reporter_for_tests import FunctionalTestReporter
3533

36-
MessageCounter = CounterType[Tuple[int, str]]
34+
MessageCounter = Counter[tuple[int, str]]
3735

3836
PYLINTRC = Path(__file__).parent / "testing_pylintrc"
3937

@@ -108,9 +106,6 @@ def __init__(
108106
self._check_end_position = (
109107
sys.version_info >= self._linter.config.min_pyver_end_position
110108
)
111-
# TODO: PY3.9: PyPy supports end_lineno from 3.9 and above
112-
if self._check_end_position and IS_PYPY:
113-
self._check_end_position = sys.version_info >= (3, 9) # pragma: no cover
114109

115110
self._config = config
116111

0 commit comments

Comments
 (0)