You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@sling.apache.org by "Stefan Seifert (JIRA)" <ji...@apache.org> on 2016/09/29 16:23:22 UTC

[jira] [Resolved] (SLING-6077) sling-mock: ResourceResolverFactory is registered twice

     [ https://issues.apache.org/jira/browse/SLING-6077?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Stefan Seifert resolved SLING-6077.
-----------------------------------
    Resolution: Fixed

Completed: At revision: 1762809  

to be precise this was not an error in sling-mock itself, but in the underlying {{org.apache.sling.resourceresolver}} and {{org.apache.sling.jcr.resource}} implementations that where used. fixed by updating to a slightly newer version of both.

> sling-mock: ResourceResolverFactory is registered twice
> -------------------------------------------------------
>
>                 Key: SLING-6077
>                 URL: https://issues.apache.org/jira/browse/SLING-6077
>             Project: Sling
>          Issue Type: Bug
>          Components: Testing
>    Affects Versions: Testing Sling Mock 2.1.0
>            Reporter: Stefan Seifert
>            Assignee: Stefan Seifert
>              Labels: mocks
>             Fix For: Testing Sling Mock 2.1.2
>
>
> when using sling mocks the ResourceResolverFactory service is registered twice. this is not obvious because everything is well for most operations.
> but if an OSGi service references it like this:
> {code:java}
>     @Reference
>     private ResourceResolverFactory factory;
> {code}
> it fails because multiple references exist (i'm not sure if this is 100% correct in the osgi-mock, need to look up the DS spec).



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