Is there an easy way to configure the JNDI environment for Unittests from the Spring XML file and export some materials (e.g. data sources)? This is SimpleNamingContextBuilder , but it will require code to set up the JNDI environment, and I would like to be able to simply include the XML file in @ContextConfiguration.
I would recommend using SimpleJNDI . You can get it from Maven Central .
In many cases, you can avoid the main problem of this issue with these solutions:
, JVM, JNDI, , , .