[
https://issues.apache.org/jira/browse/SLING-13142?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=18070236#comment-18070236
]
Stefan Seifert commented on SLING-13142:
----------------------------------------
if you are using AEM projects with AEM mocks, i recommend to follow this
approach
[https://wcm.io/testing/aem-mock/usage-maven-dependencies.html]
please try to use the {{io.wcm.maven.aem-cloud-dependencies}} version matching
the AEM SDK version you are using - or check the dependencies declared in the
POM and apply them to your project.
> Latest sling.testing.sling-mock-oak not compatible with jackrabbit oak-jcr
> 1.90 & 1.92
> --------------------------------------------------------------------------------------
>
> Key: SLING-13142
> URL: https://issues.apache.org/jira/browse/SLING-13142
> Project: Sling
> Issue Type: Bug
> Components: Testing
> Affects Versions: Testing Sling Mock Oak 4.1.0-1.86.0
> Reporter: Robert Rathsack
> Priority: Major
>
> Our Prod environment was updated to use jackrabbit.oak-jcr 1.90.0 (and they
> are preparing to update to 1.92). In our dependency settings we could not
> update this provided dependency to this version because our tests would fail
> with such errors:
>
> {{java.lang.RuntimeException: Unable to invoke method 'activate' for class
> org.apache.sling.testing.mock.sling.oak.OakMockSlingRepository}}
> {{ at
> org.apache.sling.testing.mock.osgi.OsgiServiceUtil.invokeMethod(OsgiServiceUtil.java:379)}}
> {{ at
> org.apache.sling.testing.mock.osgi.OsgiServiceUtil.lambda$invokeLifecycleMethod$0(OsgiServiceUtil.java:188)}}
> {{ at
> org.apache.sling.testing.mock.osgi.OsgiServiceUtil.findAndInvokeNearestMethod(OsgiServiceUtil.java:141)}}
> {{ at
> org.apache.sling.testing.mock.osgi.OsgiServiceUtil.invokeLifecycleMethod(OsgiServiceUtil.java:177)}}
> {{ at
> org.apache.sling.testing.mock.osgi.OsgiServiceUtil.activateDeactivate(OsgiServiceUtil.java:88)}}
> {{ at
> org.apache.sling.testing.mock.osgi.MockOsgi.registerInjectActivateService(MockOsgi.java:254)}}
> {{ at
> org.apache.sling.testing.mock.sling.ResourceResolverFactoryInitializer.registerServiceIfNotPresent(ResourceResolverFactoryInitializer.java:235)}}
> {{ at
> org.apache.sling.testing.mock.sling.ResourceResolverFactoryInitializer.registerServiceIfNotPresent(ResourceResolverFactoryInitializer.java:218)}}
>
> In the past, those errors were every time related to a missing update of the
> Sling Mock Oak lib. Therefore, please create a release to support oak-jcr
> 1.90 and 1.92
--
This message was sent by Atlassian Jira
(v8.20.10#820010)