what i did was adding the JVM debugging parameters the IT sling instance 
startup (jar.executor.vm.options, commented out), and then attached to the IT 
JVM while it was starting up (it takes some seconds while bundles are deploying 
before the tests really gets executed, so it's no problem to attach to it 
before they start). then the IT's stopped at my breakpoints as expected.

i never used the keepJarRunning flag.

stefan

>-----Original Message-----
>From: Konrad Windszus [mailto:[email protected]]
>Sent: Friday, December 05, 2014 4:42 PM
>To: [email protected]
>Subject: Debugging Sling Models IT
>
>
>HI,
>I need some help with resolving failures in the models.integration-
>tests module (don’t worry, those only fail for me due to some local
>changes).
>I tried to run the integration-tests with mvn install with the option
><keepJarRunning>true</keepJarRunning> (set inside the pom.xml) and to
>start the launchpad with the remote debugging options set.
>Now I get the following exception when executing the integration test
>
>32492 [main] ERROR org.apache.sling.models.it.RemoteIT - Exception in
>maybeStartServer()
>java.lang.IllegalMonitorStateException
>       at java.lang.Object.wait(Native Method)
>       at java.lang.Object.wait(Object.java:503)
>       at
>org.apache.sling.testing.tools.sling.SlingTestBase.blockIfRequested(Sl
>ingTestBase.java:234)
>       at
>org.apache.sling.testing.tools.sling.SlingTestBase.startServerIfNeeded
>(SlingTestBase.java:152)
>       at
>org.apache.sling.testing.tools.sling.SlingTestBase.getServerBaseUrl(Sl
>ingTestBase.java:211)
>       at
>org.apache.sling.models.it.RemoteIT.getJunitServletUrl(RemoteIT.java:2
>8)
>       at
>org.apache.sling.junit.remote.testrunner.SlingRemoteTestRunner.maybeEx
>ecuteTests(SlingRemoteTestRunner.java:95)
>       at
>org.apache.sling.junit.remote.testrunner.SlingRemoteTestRunner.getChil
>dren(SlingRemoteTestRunner.java:138)
>       at
>org.junit.runners.ParentRunner.getFilteredChildren(ParentRunner.java:3
>63)
>       at
>org.junit.runners.ParentRunner.getDescription(ParentRunner.java:297)
>       at org.junit.runners.ParentRunner.run(ParentRunner.java:305)
>       at
>org.apache.maven.surefire.junit4.JUnit4Provider.execute(JUnit4Provider
>.java:264)
>       at
>org.apache.maven.surefire.junit4.JUnit4Provider.executeTestSet(JUnit4P
>rovider.java:153)
>       at
>org.apache.maven.surefire.junit4.JUnit4Provider.invoke(JUnit4Provider.
>java:124)
>       at
>org.apache.maven.surefire.booter.ForkedBooter.invokeProviderInSameClas
>sLoader(ForkedBooter.java:200)
>       at
>org.apache.maven.surefire.booter.ForkedBooter.runSuitesInProcess(Forke
>dBooter.java:153)
>       at
>org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:1
>03)
>
>I don’t know why the IllegalMonitorStateException is triggered there.
>Any idea?
>Thanks in advance,
>Konrad

Reply via email to