Package org.codice.ddf.test.common
Class AbstractComponentTest
java.lang.Object
org.codice.ddf.test.common.AbstractComponentTest
Abstract base class for component tests. Extend to provide and implementation for the
getApplicationOptions(PortFinder) methods and the test methods.
It is important to remember that the config() method and all the methods it calls,
i.e., getContainerOptions() and getApplicationOptions(PortFinder), are called
inside the test runner process and are only used to configure the test container. All the other
methods in this class and its sub-classes will be run inside the test container, which is a
separate process.
- See Also:
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionorg.ops4j.pax.exam.Option[]config()Configuration method called during Pax Exam configuration.protected abstract ApplicationOptionsgetApplicationOptions(PortFinder portFinder) Gets the object to use to configure the component or application inside the container.protected ContainerOptionsGets the object to use to configure the container.
-
Field Details
-
testFailureLogger
-
-
Constructor Details
-
AbstractComponentTest
public AbstractComponentTest()
-
-
Method Details
-
config
public org.ops4j.pax.exam.Option[] config()Configuration method called during Pax Exam configuration. TheOptions returned will be used by Pax Exam to configure the container that will be spawn and used to execute the tests.- Returns:
- Pax Exam
Optionthat will be used to configure the Pax Exam test container
-
getContainerOptions
Gets the object to use to configure the container.- Returns:
- object that returns the container's configuration
Options. Default implementation returnsKarafOptions.
-
getApplicationOptions
Gets the object to use to configure the component or application inside the container.- Parameters:
portFinder- reference to thePortFinderto use during the test container configuration- Returns:
- object that returns the application's configuration
Options
-