Junit AEM to mock a resource is returning null
Hi all,
I am trying to mock this request to return a resource, resolver.getResource("/content/project/en/home/products/p1")
Able to get the resource object inside my test class but on invoking my actual method it returns null.
Any pointers would be helpful.
In my Test class:
lenient().when(resourceresolver.getResource("/content/project/en/home/products/p1"))
.thenReturn(childResource);

