summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorMarc Mueller <30130371+cdce8p@users.noreply.github.com>2023-04-24 00:24:48 +0200
committerGitHub <noreply@github.com>2023-04-24 00:24:48 +0200
commit7fa848126c8178e78c47dff0415a1fc175b041eb (patch)
tree4fb9818b6eb1346ce6396831819756ef9be6aedb /tests
parenta91a8d60ccd5ca8e5f8e162d67b3b93444105235 (diff)
downloadastroid-git-7fa848126c8178e78c47dff0415a1fc175b041eb.tar.gz
Remove cachedproperty decorator (#2140)
Diffstat (limited to 'tests')
-rw-r--r--tests/test_decorators.py18
1 files changed, 1 insertions, 17 deletions
diff --git a/tests/test_decorators.py b/tests/test_decorators.py
index 8a254926..28c8ee6c 100644
--- a/tests/test_decorators.py
+++ b/tests/test_decorators.py
@@ -5,8 +5,7 @@
import pytest
from _pytest.recwarn import WarningsRecorder
-from astroid.const import PY38_PLUS
-from astroid.decorators import cachedproperty, deprecate_default_argument_values
+from astroid.decorators import deprecate_default_argument_values
class SomeClass:
@@ -102,18 +101,3 @@ class TestDeprecationDecorators:
instance = SomeClass(name="some_name")
instance.func(name="", var=42)
assert len(recwarn) == 0
-
-
-@pytest.mark.skipif(not PY38_PLUS, reason="Requires Python 3.8 or higher")
-def test_deprecation_warning_on_cachedproperty() -> None:
- """Check the DeprecationWarning on cachedproperty."""
-
- with pytest.warns(DeprecationWarning) as records:
-
- class MyClass: # pylint: disable=unused-variable
- @cachedproperty
- def my_property(self):
- return 1
-
- assert len(records) == 1
- assert "functools.cached_property" in records[0].message.args[0]