One case is to start and stop docker containers. Another case is to start additional OSGi containers using PaxExamRuntime. createContainer.
I have to use forked mode. So it makes some difference. If there is no predefined way then I will create my own class extending PaxExam that calls my hooks. Christian 2018-05-04 19:42 GMT+02:00 'Christoph Läubrich' via OPS4J < [email protected]>: > What exactly do you want to archive? > > e.g. the configure method is run "outside" the container, or you can > simply have an static insitilizer and check there if an active OSGi env is > avaiable (OSGi Phase) or not (configuration phase)... > > Beside that, if you are not using the forked mode all code already runns > in the same jvm process... > > > > Am 04.05.2018 um 17:22 schrieb Christian Schneider: > >> I would like to have code executed outside of the OSGi container in the >> process where junit runs. >> >> This used to work with @BeforeClass in older versions of pax exam. Now >> these methods are also run in OSGi. >> >> Is there some way to run my code outside in a generic way? >> >> What I did until now is to extend pax exam an override the run method. Is >> there maybe a built in way that avoids this? >> >> Christian >> >> -- >> -- >> Christian Schneider >> http://www.liquid-reality.de >> >> Computer Scientist >> http://www.adobe.com >> >> -- >> -- >> ------------------ >> OPS4J - http://www.ops4j.org - [email protected] >> >> --- >> You received this message because you are subscribed to the Google Groups >> "OPS4J" group. >> To unsubscribe from this group and stop receiving emails from it, send an >> email to [email protected] <mailto: >> [email protected]>. >> For more options, visit https://groups.google.com/d/optout. >> > > -- > -- > ------------------ > OPS4J - http://www.ops4j.org - [email protected] > > --- You received this message because you are subscribed to the Google > Groups "OPS4J" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > For more options, visit https://groups.google.com/d/optout. > -- -- Christian Schneider http://www.liquid-reality.de Computer Scientist http://www.adobe.com -- -- ------------------ OPS4J - http://www.ops4j.org - [email protected] --- You received this message because you are subscribed to the Google Groups "OPS4J" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.
