-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Pramod,

On 10/30/12 11:32 AM, p.krishnamoor...@accenture.com wrote:
> Hi,
> 
> I was working to inject the JNDI datasource context outside the 
> tomcat container. I referred this link - 
> https://blogs.oracle.com/randystuph/entry/injecting_jndi_datasources_for_junit.
>
>
> 
In order to initialize the datasource context, I had to put three
> java-naming jars (naming-java-5.0.28, naming-resources-5.5.15, 
> naming-factory-5.5.12) and now Junits are running fine.
> 
> But now my tomcat server is not starting up; it throws exception - 
> Name java:comp is not bound in this Contex
> 
> It would be nice, if someone can share some thoughts on this.

If you added those JARs to your webapp, then you'll need to remove
them because they probably interfere with the standard JNDI libraries
provided by Tomcat. Just adjust your build process such that the
libraries are not included when building the "real" webapp but *are*
included when running your unit tests.

- -chris
-----BEGIN PGP SIGNATURE-----
Version: GnuPG/MacGPG2 v2.0.17 (Darwin)
Comment: GPGTools - http://gpgtools.org
Comment: Using GnuPG with Mozilla - http://www.enigmail.net/

iEYEARECAAYFAlCRXdQACgkQ9CaO5/Lv0PDOdACdFauhqAOty9TQiFR6IkI0TBKs
v2oAnA97L74i6PRDRheJdERr1lSSNSFa
=ssn/
-----END PGP SIGNATURE-----

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org

Reply via email to