0 Replies Latest reply on Jan 24, 2013 2:51 AM by ziegenlippe

    arquillian osgi how to start bundle automatically

    ziegenlippe

      Hello,

      I use the arquillian-container-osgi-embedded-1.0.3.Final for testing with Junit. It works fine even within the eclipse workspace.

       

      But the bundle object I get injected is in state resolved, so I need to start it manually in a @Before method which also works.

      But BundleContext and Osgi service injection always fails du to the not started bundle while injection time.

       

      Is there a way to let the Arquillian embedded osgi container start the bundle automatically before running any test method. And is it anyhow possible to let

      inject Osgi services as Pax Exam does like so:

       

      @ArquillianResource

      private  Bundle bundle;

       

      @ArquillianResource

      private  MyOsgiService service;

       

      Thanks,

      David