Package org.nuxeo.runtime.test.runner
Class MDCFeature
- java.lang.Object
-
- org.nuxeo.runtime.test.runner.MDCFeature
-
- All Implemented Interfaces:
RunnerFeature
public class MDCFeature extends Object implements RunnerFeature
-
-
Constructor Summary
Constructors Constructor Description MDCFeature()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
afterMethodRun(FeaturesRunner runner, org.junit.runners.model.FrameworkMethod method, Object test)
After a test method was ran.void
afterRun(FeaturesRunner runner)
After tests were run.void
afterTeardown(FeaturesRunner runner, org.junit.runners.model.FrameworkMethod method, Object test)
After the call of the @After methodsvoid
beforeMethodRun(FeaturesRunner runner, org.junit.runners.model.FrameworkMethod method, Object test)
Before a test method is invoked.void
beforeRun(FeaturesRunner runner)
Before running tests.void
beforeSetup(FeaturesRunner runner, org.junit.runners.model.FrameworkMethod method, Object test)
Before entering in the @Before methodsvoid
configure(FeaturesRunner runner, com.google.inject.Binder binder)
Configures Guice bindings if any is required by the feature.void
initialize(FeaturesRunner runner)
Called when preparing to run the test class.void
start(FeaturesRunner runner)
Features are initialized.void
stop(FeaturesRunner runner)
Before exiting the test.void
testCreated(Object test)
Notification that a test instance was created.-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.nuxeo.runtime.test.runner.RunnerFeature
afterTeardown, beforeSetup
-
-
-
-
Field Detail
-
F_TEST
protected static final String F_TEST
- See Also:
- Constant Field Values
-
F_SUITE
protected static final String F_SUITE
- See Also:
- Constant Field Values
-
F_STATE
protected static final String F_STATE
- See Also:
- Constant Field Values
-
-
Method Detail
-
initialize
public void initialize(FeaturesRunner runner)
Description copied from interface:RunnerFeature
Called when preparing to run the test class. Framework is not started at this point. Here is time for the feature to configure the runner from annotations on the test class.- Specified by:
initialize
in interfaceRunnerFeature
-
configure
public void configure(FeaturesRunner runner, com.google.inject.Binder binder)
Description copied from interface:RunnerFeature
Configures Guice bindings if any is required by the feature. This is called after the framework is started and before Guice module is built. The tests are launched after guice module is built.- Specified by:
configure
in interfaceRunnerFeature
-
beforeRun
public void beforeRun(FeaturesRunner runner)
Description copied from interface:RunnerFeature
Before running tests. At this point Guice modules are registered and injector created.- Specified by:
beforeRun
in interfaceRunnerFeature
-
afterRun
public void afterRun(FeaturesRunner runner)
Description copied from interface:RunnerFeature
After tests were run.- Specified by:
afterRun
in interfaceRunnerFeature
-
start
public void start(FeaturesRunner runner)
Description copied from interface:RunnerFeature
Features are initialized. Runner is ready to create the injector.- Specified by:
start
in interfaceRunnerFeature
-
testCreated
public void testCreated(Object test)
Description copied from interface:RunnerFeature
Notification that a test instance was created. Can be used by features to make custom injection or other preparation of the test instance.- Specified by:
testCreated
in interfaceRunnerFeature
-
stop
public void stop(FeaturesRunner runner)
Description copied from interface:RunnerFeature
Before exiting the test.- Specified by:
stop
in interfaceRunnerFeature
-
beforeSetup
public void beforeSetup(FeaturesRunner runner, org.junit.runners.model.FrameworkMethod method, Object test)
Description copied from interface:RunnerFeature
Before entering in the @Before methods- Specified by:
beforeSetup
in interfaceRunnerFeature
-
afterTeardown
public void afterTeardown(FeaturesRunner runner, org.junit.runners.model.FrameworkMethod method, Object test)
Description copied from interface:RunnerFeature
After the call of the @After methods- Specified by:
afterTeardown
in interfaceRunnerFeature
-
beforeMethodRun
public void beforeMethodRun(FeaturesRunner runner, org.junit.runners.model.FrameworkMethod method, Object test)
Description copied from interface:RunnerFeature
Before a test method is invoked.- Specified by:
beforeMethodRun
in interfaceRunnerFeature
-
afterMethodRun
public void afterMethodRun(FeaturesRunner runner, org.junit.runners.model.FrameworkMethod method, Object test)
Description copied from interface:RunnerFeature
After a test method was ran.- Specified by:
afterMethodRun
in interfaceRunnerFeature
-
-