Hello Guys,
i want to implement unit tests into my maxcul plugin.
Can somebody explain me how testing in Pimatic and Node.js works?
I have written test in php but newer in node.
Regards
Florian
Unit test help
Hello Guys,
i want to implement unit tests into my maxcul plugin.
Can somebody explain me how testing in Pimatic and Node.js works?
I have written test in php but newer in node.
Regards
Florian
@fbeek said in Unit test help:
Can somebody explain me how testing in Pimatic and Node.js works?
Sorry, I can’t give you a detailed description right now. Please have a look at https://github.com/philip1986/pimatic-led-light which implements some mocha tests using a app stub to fake pimatic and a driver stub to fake the underlying hardware driver libraries. The app stub may be outdated as it has been written for pimatic 0.8.
The starting point for these tests is script in hook in the package.json - https://github.com/philip1986/pimatic-led-light/blob/master/package.json#L17
"It always takes longer than you expect, even when you take into account Hofstadter's Law.", Hofstadter's Law