Question
Unit test case
Hi Community members, I am new to unit testing in Pega. Can anyone give a work example of a unit test case along with sample assertion. Though I have gone through pdn content and below video, I am unable to find working example of unit testing.
https://community.pega.com/video-library/how-unit-test-when-rule
To be more specific,
1.Can anyone explain why and how to use assertion for test case?
2.Do we write test case only for sucess scenario?
3.Should we also write test case for failure scenario?
For unit testing you should refer to PegaUnit : https://community.pega.com/knowledgebase/articles/pega-unit-testing
PegaUnit is the best way to unit test rules in Pega. For a sense of the latest and greatest features in PegaUnit, take a look a the What New : https://community.pega.com/knowledgebase/articles/devops-and-automated-testing-8-1