IF Node
The IF Node provides conditional logic, allowing you to execute different branches of your test flow based on a defined condition.
It is a group node that contains the “then” branch as its direct children. An optional “else” branch can be linked.
Configuration
clause: This contains thePredicatethat will be evaluated.expression: A JSONata expression that must evaluate totruefor the “then” branch to be executed. The expression has access to the test context.
thenId/elseId: These are internal identifiers for the start of the “then” and “else” branches.
How it Works
- The JSONata
expressionin theclauseis evaluated. - If the result is
true, the child nodes nested directly under the IF node are executed. - If the result is
false, the flow skips the child nodes and proceeds to the linked “else” branch, or to the node following the IF block if no “else” is configured.