Unit test of decision tree is not working properly
Unable to perform a Unit test for a Decision tree.
Steps to Reproduce
- Create a Decision Tree with a page level property as the input property.
- Run the Decision Tree by providing input values to the ID property.
- Click the Reset Page button.
The Decision Tree cannot be tested as input properties are missing.
This behavior is as per Pega product design. The decision tree displays a value when the Run button is clicked. The pages referenced in Pages and Classes of a decision tree are populated and include an input value which the decision tree requires (Goal Seek behavior). These pages are equivalent to a Clipboard page. Clicking the Reset Page button, resets the test page. When the decision tree is run, it searches for the the CustomerPage.ID which is already present on the Clipboard as the Top Level page with the value that was already populated in the earlier runs.
Perform the following local-change to reset pages to recalculate,
- Run a data transform to reset or remove the pages from the Clipboard by going to the thread in which the decision tree is run.
- Right click page with inputs and click Delete Page.
- Run the decision tree.
0% found this useful