Node-RED

JavaScript/TypeScript

A good way to write our own Node-RED node for the testability

IhaveusedNode-REDformorethan3yearsformyworkingproject.Icameupwithagoodideatowriteourownnodeforthetestability,soIwanttosh...
JavaScript/TypeScript

Node-RED flow test is slow if flow is big

IhavetriedseveraltimestoreducetesttimeofNode-REDflowtestandfailed.Fortheflowtest,Iusenode-red-node-test-helpermodulethat...
JavaScript/TypeScript

How to implement Node-RED node in TypeScript

TheofficialsitedescribeshowtoimplementourownnodeinJavaScript.However,Idon'tfindapageforTypeScript.I'veimplementedmyownno...
JavaScript/TypeScript

Tips to reduce Node-RED flow conflicts

It'shardtoavoidmergeconflictswhenusingNode-REDinabigproject.Ihavefoughtagainstmergeconflictsmanytimes.Youmaybeusingatool...
JavaScript/TypeScript

Node-RED node test fails when using sinon.useFakeTimer

Node-REDtestfailswhenreplacingtimerrelatedfunctions.OurownnodederivesNode-REDnodeanditcallssetImmediatefunction.Therefor...
JavaScript/TypeScript

How to write Node-RED flow test

Testing the whole Node-RED flow is important but adding test flows is not a good idea. Test stuff should exist only in the test code. This post explains how to write Node-RED flow tests in JavaScript/TypeScript code.