Use foremanReact directly in plugin tests

This feature is now merged in Katello which means we can use foremanReact code in our testing. Fixes #29637 - Allow jest test to use foremanReact · Katello/katello@cb8ed4d · GitHub

Any other plugins who would like to do the same can follow the same pattern. Feel free to ask any questions here.

These are all great points and the reality that we have to face with our project and the modern JS ecosystem. A lot of these topics were touched on in An Independent UI for Foreman and Plugins - Discussion and Investigation - #20 by TimoGoebel, where our plugin system and having the ability to use in-house plugins installed at runtime make having an independent UI difficult. This thread is getting a bit off topic from the original topic, so I encourage any further architecture discussions to happen in the thread I linked or a new topic :slightly_smiling_face:

I hope being able to use foremanReact in plugin tests will encourage more centralization and standardization of JS code in Foreman and make it easier for plugins to re-use code.

2 Likes