You need to sign in to do that
Don't have an account?
FabienHuot
Winter'19 : Flow and Test coverage
Hi everybody,
Since the Winter'19, there are some things I really don't understand with "Flows" and Test corevage.
From Salesforce's doc here : https://sforce.co/2PqALZw
"For example, if you have 10 active autolaunched flows and processes, and 8 of them have test coverage, your org’s flow test coverage is 80%."
How can we test "Flows", or the real question is : How Salesforce test flow ?. How can I visualize if my flow is coreved.
This query below is used to know which of my flows are not covered.
When executing this query, Salesforce tells me that I have some flow not covered, but how can I cover them?
How Salesforce decide if my flow is covered or not ?
Thanks for your help :)
Since the Winter'19, there are some things I really don't understand with "Flows" and Test corevage.
From Salesforce's doc here : https://sforce.co/2PqALZw
"For example, if you have 10 active autolaunched flows and processes, and 8 of them have test coverage, your org’s flow test coverage is 80%."
How can we test "Flows", or the real question is : How Salesforce test flow ?. How can I visualize if my flow is coreved.
This query below is used to know which of my flows are not covered.
SELECT Definition.DeveloperName FROM Flow WHERE Status = 'Active' AND (ProcessType = 'AutolaunchedFlow' OR ProcessType = 'Workflow' OR ProcessType = 'CustomEvent' OR ProcessType = 'InvocableProcess') AND Id NOT IN (SELECT FlowVersionId FROM FlowTestCoverage)
When executing this query, Salesforce tells me that I have some flow not covered, but how can I cover them?
How Salesforce decide if my flow is covered or not ?
Thanks for your help :)
Please see attached link - https://releasenotes.docs.salesforce.com/en-us/winter19/release-notes/rn_forcecom_flow_test_coverage.htm
I hope it helps you.
Kindly let me know if it helps you and close your query by marking it as solved so that it can help others in the future.
Thanks and Regards,
Sagar Jogi
Hi Sagar,
And how can I create a test that covers my flow. For instance. I have an autolaunched flow. Everytime I modify a record of my customObject__c, a trigger checks if a field has a certain value. If so, it calls the flow.
I get a new record that shows my test class.My first thought was to create a test class that covers the trigger. Basically I just create a record with the expected value.
Now, if I run the query:
However if I run: the autolaunched flow appears, so really confused.
On the other side, shall I guess that there is no way to test "Screen Flow" flows?
Thanks!!
Thanks!!