Hi all. I'm currently investigating flow tests for our org. I am able to set up my test fine in my development sandbox, but once deploying to a staging org, I get invalid references since it appears to be hard-coding the lookup ids.
Example: I have a flow that initiates from a Product Request Line Item that is associated with a specific workorder. The flow looks at data on the workorder for routing during a few decisions, so I'm populating a workorder in the workorder field on the Product Request Line Item test data. The metadata shows the workorder Id as hardcoded into it, and in the target org when running the test, I get an invalid reference error, as that workorder does not exist in that org.
Has anyone come up with a workaround for this issue?
Flow Test feature does not do full data siloing like Apex Test Classes. Therefore, IDs from sandbox to another environment will change. You'll have to redo the lookup ids for each environment by editing the test again since Flow Test uses environment data for running the tests.