Oh, well, since you're implementing `__init__` the class has actually already been created.  In your above example it should work to use `getattr(cls, 'test')`.