Discussion
Pegasystems Inc.
JP
Last activity: 25 Aug 2022 11:06 EDT
Unable to create a test case rule on flow rule with Pega 8.5+
Hi,
Customer reported that they can’t create a test case rule on flow rule after they upgraded to Pega 8.5.
1. Symptom
Customer used to create a test case on flow rule for unit testing before, but after they upgraded their platform to 8.5, the functionality became unavailable. Till 8.4, test case rule was creatable for any flow rules including pyStartCase as long as the flow rule is in draft mode. In 8.5+, the “Record test case” menu is gone regardless of draft mode. Please see below two screenshots of action menu in 8.4 and 8.5.
2. Root cause
Starting with 8.5, the concept of starting flows "pyStartCase" is removed. As a side effect, flows are not runnable from action menu. Test case is creatable only when a flow is runnable, hence in 8.5+, unit testing capabilities are not provided anymore for the flow rule.
3. Enhancement Request
My customer actually private-edited Rule-Obj-Flow.pzRuleFormToolbarShowRunForFlow when rule (Final) and temporarily made it return always true. This approach forcibly makes the "Record test case" menu to show up.
According to them, all the test case rules created by this approach worked fine throughout their projects. However, this is not recommended and I asked them to stop doing this. I’ve created an FDBK item to take back the functionality. In the meantime, I would advise to use Scenario testing or Case Type of Unit testing for any UI-based testing.
Hope this helps.
Thanks,