summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorPierre Sassoulas <pierre.sassoulas@gmail.com>2023-03-14 19:43:31 +0100
committerGitHub <noreply@github.com>2023-03-14 19:43:31 +0100
commitce07459e1e6cd636dd3c4bb26b7cadeec8de6001 (patch)
treefe6d6bdec9a9b8fa3ced6f6f11a52b4bc6c5a3c1 /tests
parent886da706f0f88df667099dad915a581338779ef1 (diff)
downloadastroid-git-ce07459e1e6cd636dd3c4bb26b7cadeec8de6001.tar.gz
Upgrade pre-commit configuration and move to ruff (#2057)
Diffstat (limited to 'tests')
-rw-r--r--tests/test_inference.py3
-rw-r--r--tests/test_nodes.py2
-rw-r--r--tests/test_regrtest.py2
3 files changed, 3 insertions, 4 deletions
diff --git a/tests/test_inference.py b/tests/test_inference.py
index ef99e031..6ac55a42 100644
--- a/tests/test_inference.py
+++ b/tests/test_inference.py
@@ -17,9 +17,8 @@ from unittest.mock import patch
import pytest
-from astroid import Slice, arguments
+from astroid import Slice, arguments, helpers, nodes, objects, test_utils, util
from astroid import decorators as decoratorsmod
-from astroid import helpers, nodes, objects, test_utils, util
from astroid.arguments import CallSite
from astroid.bases import BoundMethod, Instance, UnboundMethod, UnionType
from astroid.builder import AstroidBuilder, _extract_single_node, extract_node, parse
diff --git a/tests/test_nodes.py b/tests/test_nodes.py
index 06334346..2c7d95b7 100644
--- a/tests/test_nodes.py
+++ b/tests/test_nodes.py
@@ -998,7 +998,7 @@ class AliasesTest(unittest.TestCase):
def test_aliases(self) -> None:
def test_from(node: ImportFrom) -> ImportFrom:
- node.names = node.names + [("absolute_import", None)]
+ node.names = [*node.names, ("absolute_import", None)]
return node
def test_class(node: ClassDef) -> ClassDef:
diff --git a/tests/test_regrtest.py b/tests/test_regrtest.py
index 783f1cc1..46db87ea 100644
--- a/tests/test_regrtest.py
+++ b/tests/test_regrtest.py
@@ -267,7 +267,7 @@ def test(val):
"With unicode : {'’'} "
instance = MyClass()
- """
+ """ # noqa[RUF001]
)
next(node.value.infer()).as_string()