teemtee / tmt

Test Management Tool
MIT License
82 stars 123 forks source link

Support dynamic plugins support for the test framework #761

Open psss opened 3 years ago

psss commented 3 years ago

Currently the implementation for the two supported frameworks shell and beakerlib is hard-coded in the tmt.steps.execute module, mainly by the check_shell() and check_beakerlib() methods. It would be nice to clean up the implementation and move the framework code into a separate modules which would be dynamically loaded as plugins. This would allow better extensibility in the future.

jscotka commented 3 years ago

Would be nice, to have it as separate check plugins for shell and beakerlib frameworks, thats true, than have it hardcoded.

As we've discussed on meeting. Not sure if also some other framework has special handling as beakerlib needs.

I think that most of frameworks indicates via return code state of run + possible to output all necessary info to stdout. e.g.

So from my perspective beakerlib handling does much more than framework, and it is more less exception than typical framwork behaviour.

another think is that lots of frameworks allows to generate e.g. xunit outputs, so that instead of special frameworks odules, it could be enough use current ones maybe + xunit/junit output parser.

pvalena commented 3 years ago

Would be nice, to have it as separate check plugins for shell and beakerlib frameworks, thats true, than have it hardcoded.

I think we could make it really simple to create the frameworks, like inheriting mostly everything from shell and changing just few methods.

psss commented 3 years ago

@ZhukovGreen, would you be possibly interested in looking into this?

zhukovgreen commented 3 years ago

I will, thx @psss