[ https://issues.apache.org/jira/browse/SLING-4500?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14386443#comment-14386443 ]
Robert Munteanu edited comment on SLING-4500 at 3/30/15 9:23 AM: ----------------------------------------------------------------- Patch applied in https://svn.apache.org/r1670023 , thank you for the contribution! _Edit_: typo was (Author: rombert): Patch applies in https://svn.apache.org/r1670023 , thank you for the contribution! > using Sling mocks throws NullPointerException when checking the resourceType > of the root node > --------------------------------------------------------------------------------------------- > > Key: SLING-4500 > URL: https://issues.apache.org/jira/browse/SLING-4500 > Project: Sling > Issue Type: Bug > Components: Testing > Affects Versions: Testing ResourceResolver Mock 1.1.4 > Reporter: santiago garcĂa pimentel > Assignee: Robert Munteanu > Priority: Minor > Fix For: Testing ResourceResolver Mock 1.1.6 > > > when using the Mocked ResourceResolver > (org.apache.sling.testing.resourceresolver.MockResourceResolver), the root > node does not have a primary type, this causes that something like > Resource root= resourceResolver.getResource("/"); > root.isResourceType("app/resourceType"); > will throw a NPE, since the node does not have either resourceType or primary > type. > Instead, the root node should have a primary type. -- This message was sent by Atlassian JIRA (v6.3.4#6332)