I'm am in the process of setting up Junit testing for my Jackrabbit based CMS web application using JSF and Spring. I finally got my test to see the config files I need, but now I get the following error message. It seems like the JcrTemplate isn't opening up a new JCR session so that I can access the repository. Everything works fine when the application is deployed...just not for my Junit test. Since I don't get any errors about being able to initialize any of my Dependency Injected beans...i would assume everything is initialized properly. Does anyone know what i'm missing? Do I need to set something in the AbstractDependencyInjectionSpringContextTests class to initialize the repository?
javax.jcr.RepositoryException: this session has been closed at org.apache.jackrabbit.core.SessionImpl.sanityCheck (SessionImpl.java:353) at org.apache.jackrabbit.core.ItemImpl.sanityCheck(It emImpl.java:153) at org.apache.jackrabbit.core.NodeImpl.getUUID(NodeIm pl.java:2803) at org.bmpcoe.cwe5.service.impl.NodeServiceImpl.getNo deByPath(NodeServiceImpl.java:165) at org.bmpcoe.cwe5.service.NodeServiceTests.testGetAl lFiles(NodeServiceTests.java:41) at org.springframework.test.ConditionalTestCase.runBa re(ConditionalTestCase.java:69) at org.eclipse.ant.internal.ui.antsupport.EclipseDefa ultExecutor.executeTargets(EclipseDefaultExecutor. java:32) at org.eclipse.ant.internal.ui.antsupport.InternalAnt Runner.run(InternalAntRunner.java:423) at org.eclipse.ant.internal.ui.antsupport.InternalAnt Runner.main(InternalAntRunner.java:137) -- View this message in context: http://www.nabble.com/Junit-testing-with-Jackrabbit-using-AbstractDependencyInjectionSpringContextTests-tf4111862.html#a11691587 Sent from the Jackrabbit - Dev mailing list archive at Nabble.com.
