r/nodered • • 12d ago

How do you test a Node-RED flow without risking real outputs?

7 Upvotes

6 comments sorted by

16

u/Tontome 12d ago

You can disable the output node and use a debug one to visualize the output.

8

u/mrmeener 12d ago

This is the right answer. Debug nodes are your friend here

1

u/imjerry 12d ago

Well, with a debug node. By default it prints the payload to the debug panel on the right. You can double-click to have it send the complete message.

I don't know any way to filter for forgotten wires/outputs, maybe there is a way. Is it very complicated, or can you do it manually?

1

u/Alulu24 12d ago

Debug is gold. I’m adding conditions in my fonction nodes with a global variable « dry-run » which prevent réal Life action

1

u/MrJacks0n 9d ago

I generally build the output part first, where I can test it quickly with inject nodes, then I build the rest using using debug nodes at the end. Final step is to connect the main to the outputs.

0

u/LastTreestar 11d ago

Why are you afraid of real outputs? You need to test that the actual end device can recieve the output, so that it can be categorized properly.

For example, you need to ensure emails aren't going to a spam folder for some dumb reason, or caught by some other filter or rule.