diff options
Diffstat (limited to 'tests')
-rw-r--r-- | tests/test_decorators.py | 18 |
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] |