Expand my Community achievements bar.

Don’t miss the AEM Skill Exchange in SF on Nov 14—hear from industry leaders, learn best practices, and enhance your AEM strategy with practical tips.
SOLVED

How can I write unit test cases for extended core component models

Avatar

Level 4

I have created some sling models by using a delegation pattern(by extending core components) but I've had some issues while writing unit test cases for these sling models.

Hopefully, someone can give me some suggestions. thanks

Thanks

1 Accepted Solution

Avatar

Correct answer by
Community Advisor

Hi @jerinraj5555 

Please have a look at the following test case written for class extending core component class.
https://github.com/adobe/aem-core-wcm-components/blob/main/bundles/core/src/test/java/com/adobe/cq/w...

Thanks,
Himanshu Singhal

View solution in original post

2 Replies

Avatar

Correct answer by
Community Advisor

Hi @jerinraj5555 

Please have a look at the following test case written for class extending core component class.
https://github.com/adobe/aem-core-wcm-components/blob/main/bundles/core/src/test/java/com/adobe/cq/w...

Thanks,
Himanshu Singhal