1 Reply Latest reply on Jan 26, 2011 8:05 AM by aslak

    EnterpriseArchive can not find BeanManager

    pieter.martin

      Hi,

       

      I am running arquillian 1.0.0.Alpha4 on jboss 6.0.0.Final.

       

      I can succesfully test a cdi bean in a JavaArchive and in a WarArchive but when I try an EnterpriseArchive the BeanManager can for some reason not be found in the JNDI.

       

      I get the following in the log,

       

      INFO  [org.jboss.arquillian.testenricher.cdi.CDIInjectionEnricher] (http-localhost%2F127.0.0.1-8080-1) BeanManager cannot be located at java:comp/BeanManager. Either you are using an archive with no beans.xml, or the BeanManager has not been bound to that location in JNDI.

       

      The archive does have a beans.xml and when I inspec the JNDI via the jmxconsole I can see the BeanManager bound at java:comp/BeanManager

       

      In the test case if I user @EJB rather than @Inject then it succeeds.

       

      Am I missing something?

       

      Thanks

      Pieter