Konrad Windszus created SLING-4654:
--------------------------------------

             Summary: Support ResourceResolver.findResources with JCR_MOCK
                 Key: SLING-4654
                 URL: https://issues.apache.org/jira/browse/SLING-4654
             Project: Sling
          Issue Type: Improvement
          Components: Testing
    Affects Versions: Testing Sling Mock 1.2.0
            Reporter: Konrad Windszus


Although JCR Mocks supports mocking queries 
(https://sling.apache.org/documentation/development/jcr-mock.html#mocking-queries)
 this is not being propagated to the Sling API when using Sling Mocks with 
JCR_MOCK as the resource resolver type. Whenever you execute 
{{ResourceResolver.findResource}} on such a mock it will always return no 
results.
The expected behaviour would be that any mocked queries through 
{{MockJcr.setQueryResult}} would be considered also for 
{{ResourceResolver.findResource}}. Attached is a test case for Sling Mocks 
which currently fails due to findResource not returning anything.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to