From b7bed2cced2fd4724fe438fa90fc884c821dca93 Mon Sep 17 00:00:00 2001 From: lasers Date: Mon, 23 Dec 2024 18:11:03 -0600 Subject: [PATCH] stop warning py3status/tests/test_module_load.py:5 PytestCollectionWarning: cannot collect test class 'TestModule' because it has a __init__ constructor (from: tests/test_module_load.py) class TestModule --- tests/test_module_load.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/tests/test_module_load.py b/tests/test_module_load.py index 2a60864b54..15017db5b0 100644 --- a/tests/test_module_load.py +++ b/tests/test_module_load.py @@ -5,8 +5,9 @@ class TestModule: static_variable = 123 - def __init__(self): - self.instance_variable = 321 + @classmethod + def setup_class(cls): + cls.instance_variable = 321 def post_config_hook(self): pass