Unit testing your plugins


So I have been working on adding unit testing to my Jovo V2 skill the last couple weeks. Today I switched gears and added the Slack Error reporting plugin and got it working, which is very nice!

Now I am wondering how I could add some unit testing for this plugin, as well as I have a dashbot plugin installed that have no actual unit tests.

Anyone else out there have tests setup for these nifty plugins or ideas on how that would work?

To test while I added the Slack plugin, I added a error intent that I could call saying “I am error” and just returned a tell with no speech. However, I cannot keep that in and still get certified, so not a good long term plan.


Hi @natrixx, thank you, this is an interesting question.

Just to clarify: You want to add unit tests for a plugin to your application rather than add unit tests to a plugin itself?

Maybe @AlexSwe, @rubenaeg, or @Kaan_Kilic can help, who have most experience with writing unit tests for the framework.


@jan - that is correct, I would like to test my implementation of the plugin rather than the plugin itself.

Having thought it about it some more since asking, I suspect being able to mock some stuff would come in handy here, as mentioned in this link: Feature Proposal: Same-process testing