Inheriting avocado.test.Test

Marius Vollmer marius.vollmer at redhat.com
Wed Mar 11 14:57:10 UTC 2015


Lukáš Doktor <ldoktor at redhat.com> writes:

> I'm not sure what can be done to avoid parsing imported classes as
> they are internally just variables.

You can check the module that they (probably) are defined in with
inspect.getmodule and identify imported classes this way.  That helps in
my case.

Another approach might be to ignore classes that have subclasses of
their own.

Of course, Avocade should also have a way to explicitly specify the
classes to test.

> So the solution with importing cockpit instead of CockpitTest is a
> clean solution and not just workaround.

Hmm, it is a very non-obvious solution, IMO.  I at least had to read the
Avocado sources and sleep on it to come up with it.  It should at least
be documented, I'd say.


More information about the cockpit-devel mailing list