summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
Diffstat (limited to 'tests')
-rw-r--r--tests/benchmark/test_baseline_benchmarks.py2
-rw-r--r--tests/checkers/unittest_design.py1
-rw-r--r--tests/checkers/unittest_format.py4
-rw-r--r--tests/config/unittest_config.py1
-rw-r--r--tests/conftest.py1
-rw-r--r--tests/lint/unittest_lint.py3
-rw-r--r--tests/profile/test_profile_against_externals.py2
-rw-r--r--tests/pyreverse/test_diagrams.py1
-rw-r--r--tests/regrtest_data/unused_variable.py2
-rw-r--r--tests/test_func.py1
-rw-r--r--tests/unittest_reporting.py2
11 files changed, 5 insertions, 15 deletions
diff --git a/tests/benchmark/test_baseline_benchmarks.py b/tests/benchmark/test_baseline_benchmarks.py
index 430e8995c..38347f1e7 100644
--- a/tests/benchmark/test_baseline_benchmarks.py
+++ b/tests/benchmark/test_baseline_benchmarks.py
@@ -9,7 +9,7 @@
# Licensed under the GPL: https://www.gnu.org/licenses/old-licenses/gpl-2.0.html
# For details: https://github.com/PyCQA/pylint/blob/main/LICENSE
-# pylint: disable=protected-access,missing-function-docstring,no-self-use
+# pylint: disable=missing-function-docstring
import os
import pprint
diff --git a/tests/checkers/unittest_design.py b/tests/checkers/unittest_design.py
index 441793a2e..49acfe4e9 100644
--- a/tests/checkers/unittest_design.py
+++ b/tests/checkers/unittest_design.py
@@ -58,5 +58,4 @@ class TestDesignChecker(CheckerTestCase):
Compare against actual list to see if validator works."""
options = get_global_option(self.checker, "exclude-too-few-public-methods")
- # pylint: disable-next=use-implicit-booleaness-not-comparison
assert options == []
diff --git a/tests/checkers/unittest_format.py b/tests/checkers/unittest_format.py
index a9a62c902..d432a96ae 100644
--- a/tests/checkers/unittest_format.py
+++ b/tests/checkers/unittest_format.py
@@ -293,9 +293,7 @@ def test_disable_global_option_end_of_line() -> None:
Test for issue with disabling tokenizer messages
that extend beyond the scope of the ast tokens
"""
- file_ = tempfile.NamedTemporaryFile(
- "w", delete=False
- ) # pylint: disable=consider-using-with
+ file_ = tempfile.NamedTemporaryFile("w", delete=False)
with file_:
file_.write(
"""
diff --git a/tests/config/unittest_config.py b/tests/config/unittest_config.py
index 9979aa41b..b10c686e4 100644
--- a/tests/config/unittest_config.py
+++ b/tests/config/unittest_config.py
@@ -97,5 +97,4 @@ class TestPyLinterOptionSetters(CheckerTestCase):
Compare against actual list to see if validator works."""
options = get_global_option(self.checker, "ignore-paths")
- # pylint: disable-next=use-implicit-booleaness-not-comparison
assert options == []
diff --git a/tests/conftest.py b/tests/conftest.py
index 5c2567d11..7a9c062db 100644
--- a/tests/conftest.py
+++ b/tests/conftest.py
@@ -1,5 +1,4 @@
# pylint: disable=redefined-outer-name
-# pylint: disable=no-name-in-module
import os
from pathlib import Path
diff --git a/tests/lint/unittest_lint.py b/tests/lint/unittest_lint.py
index 865d7640b..8c3c12b9b 100644
--- a/tests/lint/unittest_lint.py
+++ b/tests/lint/unittest_lint.py
@@ -70,8 +70,6 @@ from pylint.typing import MessageLocationTuple
from pylint.utils import FileState, print_full_documentation, tokenize_module
if os.name == "java":
- # pylint: disable=no-member
- # os._name is valid see https://www.programcreek.com/python/example/3842/os._name
if os.name == "nt":
HOME = "USERPROFILE"
else:
@@ -799,7 +797,6 @@ class TestPreprocessOptions:
class _CustomPyLinter(PyLinter):
- # pylint: disable=too-many-ancestors
@staticmethod
def should_analyze_file(modname: str, path: str, is_argument: bool = False) -> bool:
if os.path.basename(path) == "wrong.py":
diff --git a/tests/profile/test_profile_against_externals.py b/tests/profile/test_profile_against_externals.py
index 14b6dae71..128a34738 100644
--- a/tests/profile/test_profile_against_externals.py
+++ b/tests/profile/test_profile_against_externals.py
@@ -7,7 +7,7 @@
# Licensed under the GPL: https://www.gnu.org/licenses/old-licenses/gpl-2.0.html
# For details: https://github.com/PyCQA/pylint/blob/main/LICENSE
-# pylint: disable=protected-access,missing-function-docstring,no-self-use
+# pylint: disable=missing-function-docstring
import os
import pprint
diff --git a/tests/pyreverse/test_diagrams.py b/tests/pyreverse/test_diagrams.py
index a2da6e27d..6eb797990 100644
--- a/tests/pyreverse/test_diagrams.py
+++ b/tests/pyreverse/test_diagrams.py
@@ -4,7 +4,6 @@
# For details: https://github.com/PyCQA/pylint/blob/main/LICENSE
"""Unit test for the diagrams modules"""
-# pylint: disable=redefined-outer-name
from typing import Callable
from pylint.pyreverse.diadefslib import DefaultDiadefGenerator, DiadefsHandler
diff --git a/tests/regrtest_data/unused_variable.py b/tests/regrtest_data/unused_variable.py
index eee909d53..88bb0e7a7 100644
--- a/tests/regrtest_data/unused_variable.py
+++ b/tests/regrtest_data/unused_variable.py
@@ -1,4 +1,4 @@
-# pylint: disable=missing-docstring
+# pylint: disable=missing-module-docstring, missing-function-docstring
def test():
variable = ''
diff --git a/tests/test_func.py b/tests/test_func.py
index 914fbbc92..575773bb9 100644
--- a/tests/test_func.py
+++ b/tests/test_func.py
@@ -55,7 +55,6 @@ class LintTestUsingModule:
def _test_functionality(self) -> None:
if self.module:
tocheck = [self.package + "." + self.module]
- # pylint: disable=not-an-iterable; can't handle boolean checks for now
if self.depends:
tocheck += [
self.package + f".{name.replace('.py', '')}" for name, _ in self.depends
diff --git a/tests/unittest_reporting.py b/tests/unittest_reporting.py
index 7400be9e5..22fdc905c 100644
--- a/tests/unittest_reporting.py
+++ b/tests/unittest_reporting.py
@@ -58,7 +58,7 @@ def test_template_option(linter):
def test_deprecation_set_output(recwarn):
- """TODO remove in 3.0""" # pylint: disable=fixme
+ """TODO remove in 3.0"""
reporter = BaseReporter()
# noinspection PyDeprecation
reporter.set_output(sys.stdout)