Your browser does not seem to support JavaScript. As a result, your viewing experience will be diminished, and you have been placed in read-only mode.
Please download a browser that supports JavaScript, or enable it if it's disabled (i.e. NoScript).
If I'm developing a plugin for NodeBB, what is the recommended way to write unit tests for the plugin?
Has anyone done this who would like to share his workflow?
Do you mean you want to do integration testing? Running your plugin in a live NobeBB?
Unit tests would use a mocks (fake functions that always return expected results) to call nodebb and db methods.
I've had similar issues trying to meet things up with the style guide.
@yariplus Yes, integration testing especially. Is there any resource on how to do it with NodeBB and its plugins?
Not particularly... there's no exposure to the testing suite via plugins.
If you want to test the plugin via eslint, you can run it locally: ./node_modules/.bin/eslint .
./node_modules/.bin/eslint .