diff --git a/tests/test_deprecated.py b/tests/test_deprecated.py index e4c7259f..c4076a49 100644 --- a/tests/test_deprecated.py +++ b/tests/test_deprecated.py @@ -2,7 +2,7 @@ import pytest -from instamatic.utils.deprecated import deprecated, VisibleDeprecationWarning +from instamatic.utils.deprecated import VisibleDeprecationWarning, deprecated def test_basic(): @@ -11,7 +11,8 @@ def foo() -> int: return 1 with pytest.warns( - VisibleDeprecationWarning, match='Function foo is deprecated since 2.0, use bar instead.' + VisibleDeprecationWarning, + match='Function foo is deprecated since 2.0, use bar instead.', ): assert foo() == 1 @@ -35,7 +36,8 @@ def bar(self) -> int: return 1 with pytest.warns( - VisibleDeprecationWarning, match='Function bar is deprecated since 2.0, use baz instead.' + VisibleDeprecationWarning, + match='Function bar is deprecated since 2.0, use baz instead.', ): foo = Foo() assert foo.bar() == 1 @@ -49,7 +51,8 @@ def bar(cls) -> int: return 1 with pytest.warns( - VisibleDeprecationWarning, match='Function bar is deprecated since 2.0, use baz instead.' + VisibleDeprecationWarning, + match='Function bar is deprecated since 2.0, use baz instead.', ): foo = Foo() assert foo.bar() == 1 @@ -66,7 +69,8 @@ def bar() -> int: foo = Foo() with pytest.warns( - VisibleDeprecationWarning, match='Function bar is deprecated since 2.0, use baz instead.' + VisibleDeprecationWarning, + match='Function bar is deprecated since 2.0, use baz instead.', ): assert foo.bar() == 1 assert Foo.bar() == 1