org.ops4j.pax.exam
Interface TestContainer

All Superinterfaces:
TestTarget

public interface TestContainer
extends TestTarget

Management of an OSGi framework that can be used as a integration regression container. Each container is also a test target. When constucting TestContainers, it is good practice to not put the parsing part (from Option[]) into the implementation. Instead, make the native container construction really simple and tied to the underlying container.

Since:
0.3.0, December 09, 2008
Author:
Alin Dreghiciu (adreghiciu@gmail.com), Toni Menzel (toni@okidokiteam.com)

Method Summary
 void setBundleStartLevel(long bundleId, int startLevel)
          Sets the start level for a bundle.
 TestContainer start()
          Starts the regression container.
 TestContainer stop()
          Stops the regression container.
 
Methods inherited from interface org.ops4j.pax.exam.TestTarget
call, cleanup, install, waitForState
 

Method Detail

setBundleStartLevel

void setBundleStartLevel(long bundleId,
                         int startLevel)
                         throws TestContainerException
Sets the start level for a bundle.

Parameters:
bundleId - bundle id
startLevel - start level
Throws:
TestContainerException - if startlevel cannot be set

start

TestContainer start()
                    throws TimeoutException
Starts the regression container.

Returns:
this for fluent api
Throws:
TimeoutException - - if timeout occured and the regression container cannot be started

stop

TestContainer stop()
                   throws TimeoutException
Stops the regression container. Implementations should take care of calling cleanup() internally, too.

Returns:
this for fluent api
Throws:
TimeoutException - - if timeout occured and the regression container cannot be stopped


Copyright © 2006-2011 OPS4J - Open Participation Software for Java. All Rights Reserved.