1 Reply Latest reply on Aug 16, 2011 6:22 AM by thomas.diesler

    examples: mvn -Dtarget.container=runtime test

    cseg

      I can successfully build the examples, but the tests are failing.  I'm not exactly sure what environment I need to run them.  I'm not sure if I need to be, but I am running the JBossOSGi Runtime in one window.  In another, I try to run the tests.

       

      mvn --version returns this:

       

      $ mvn --version

      Apache Maven 3.0.3 (r1075438; 2011-02-28 12:31:09-0500)

      Maven home: C:\cygwin\nes\apache-maven-3.0.3

      Java version: 1.6.0_26, vendor: Sun Microsystems Inc.

      Java home: C:\Program Files\Java\jdk1.6.0_26\jre

      Default locale: en_US, platform encoding: Cp1252

      OS name: "windows 7", version: "6.1", arch: "amd64", family: "windows"

       

      mvn clean -Dtarget.container=runtime test produces this error:

       

      -------------------------------------------------------------------------------

      Test set: org.jboss.test.osgi.example.xml.parser.SAXParserTestCase

      -------------------------------------------------------------------------------

      Tests run: 1, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 2.697 sec <<< FAILURE!

      org.jboss.test.osgi.example.xml.parser.SAXParserTestCase  Time elapsed: 0 sec  <<< ERROR!

      java.lang.IllegalStateException: Cannot obtain MBeanServerConnection to: service:jmx:rmi:///jndi/rmi://127.0.0.1:1090/jmxrmi

              at org.jboss.arquillian.container.osgi.remote.RemoteDeployableContainer.getMBeanServerConnection(RemoteDeployableContainer.java:178)

              at org.jboss.arquillian.container.osgi.remote.RemoteDeployableContainer.setup(RemoteDeployableContainer.java:85)

              at org.jboss.arquillian.container.osgi.remote.RemoteDeployableContainer.setup(RemoteDeployableContainer.java:60)

              at org.jboss.arquillian.container.impl.client.container.ContainerLifecycleController$4.perform(ContainerLifecycleController.java:125)

              at org.jboss.arquillian.container.impl.client.container.ContainerLifecycleController$4.perform(ContainerLifecycleController.java:106)

              at org.jboss.arquillian.container.impl.client.container.ContainerLifecycleController.forContainer(ContainerLifecycleController.java:182)

              at org.jboss.arquillian.container.impl.client.container.ContainerLifecycleController.setupContainer(ContainerLifecycleController.java:105)

       

      1090 is up:

       

      $ netstat -an | grep -w 1090

        TCP    127.0.0.1:1090         0.0.0.0:0              LISTENING

       

       

      mvn clean test produces this error:

       

      -------------------------------------------------------------------------------

      Test set: org.jboss.test.osgi.example.xml.parser.SAXParserTestCase

      -------------------------------------------------------------------------------

      Tests run: 1, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 5.618 sec <<< FAILURE!

      org.jboss.test.osgi.example.xml.parser.SAXParserTestCase  Time elapsed: 0 sec  <<< ERROR!

      org.jboss.arquillian.container.spi.client.container.LifecycleException: Cannot start embedded OSGi Framework

              at org.jboss.arquillian.container.osgi.embedded.EmbeddedDeployableContainer.start(EmbeddedDeployableContainer.java:110)

              at org.jboss.arquillian.container.impl.client.container.ContainerLifecycleController$5.perform(ContainerLifecycleController.java:144)

              at org.jboss.arquillian.container.impl.client.container.ContainerLifecycleController$5.perform(ContainerLifecycleController.java:134)

              at org.jboss.arquillian.container.impl.client.container.ContainerLifecycleController.forContainer(ContainerLifecycleController.java:182)

              at org.jboss.arquillian.container.impl.client.container.ContainerLifecycleController.startContainer(ContainerLifecycleController.java:133)

       

      What am I missing?