Interested in a ServiceNow event built for developers? Registration for now[dev]26 is officially open!

flow designer testing prevent cancel approval

lcbell44
Kilo Contributor

When testing a flow, how do I prevent approvals from being canceled?

4 REPLIES 4

Ankur Bawiskar
Tera Patron

@lcbell44 

what's your actual testing scenario?

Regards,
Ankur
✨ Certified Technical Architect  ||  ✨ 10x ServiceNow MVP  ||  ✨ ServiceNow Community Leader

Tejas Adhalrao
Kilo Sage

hi @lcbell44  ,

 

When you test a Flow from Flow Designer, the actions are actually executed on the instance, so approval records can be created during the test.For testing, I would use a non-production/PDI instance and a dedicated test record/user rather than trying to prevent the approval engine from behaving normally.

 

If this helps, please mark it as Helpful and accept the solution.
Regards,
Tejas

yashkamde
Giga Sage

Hello @lcbell44 ,

 

share you flow screenshot or executions..

lcbell44
Kilo Contributor

I was able to get around it by adding a debug flow variable and putting the elements I wanted to be tested in an if debug branch.