diff --git a/tests/plugins/test_plugins.py b/tests/plugins/test_plugins.py index bfacac3..436e546 100644 --- a/tests/plugins/test_plugins.py +++ b/tests/plugins/test_plugins.py @@ -29,11 +29,13 @@ def _verify_module(module, plugin_module_name): continue obj = clazz(_TestContext()) - with pytest.raises(AttributeError, match=f"'{name}' object has no attribute '{_INVALID_METHOD}'"): + with pytest.raises( + AttributeError, + match=f"'{name}' object has no attribute '{_INVALID_METHOD}'", + ): getattr(obj, _INVALID_METHOD) assert hasattr(obj, _INVALID_METHOD) is False - for name, obj in inspect.getmembers(module, inspect.ismodule): _verify_module(obj, plugin_module_name) @@ -45,7 +47,7 @@ def test_plugins_correct_has_attr(): continue name = file.replace("/", ".") - name = name[name.find(module.__name__) : -3].removesuffix(".__init__") + name = name[name.find(module.__name__): -3].removesuffix(".__init__") __import__(name)