public class TestRunnerFacadeBean extends Object implements TestRunnerFacade
We'll use bean managed transaction management to control the transactions better.
TestRunnerFacade.ContextAware, TestRunnerFacade.DataVerifierInfo, TestRunnerFacade.Initializable, TestRunnerFacade.TestRunnerContext| Constructor and Description |
|---|
TestRunnerFacadeBean() |
| Modifier and Type | Method and Description |
|---|---|
void |
resetSystemProperties(ch.inftec.ju.util.SystemPropertyTempSetter tempSetter)
Resets the system properties to their original state.
|
Object |
runMethodInEjbContext(String className,
String methodName,
Class<?>[] argumentTypes,
Object[] args)
Runs an arbitrary method in an EJB context and returns the result of the method.
|
void |
runPostTestActionsInEjbContext(ch.inftec.ju.ee.test.TestRunnerAnnotationHandler handler)
Runs post test actions (like data set exports and data verifies) in an EJB context.
|
ch.inftec.ju.util.SystemPropertyTempSetter |
runPreTestActionsInEjbContext(ch.inftec.ju.ee.test.TestRunnerAnnotationHandler handler)
Runs pre test actions (like data set loading) in an EJB context.
|
void |
runTestMethodInEjbContext(ch.inftec.ju.ee.test.TestRunnerAnnotationHandler handler)
Runs a (test) method in an EJB context, allowing it to use container functionality and
beans.
|
public ch.inftec.ju.util.SystemPropertyTempSetter runPreTestActionsInEjbContext(ch.inftec.ju.ee.test.TestRunnerAnnotationHandler handler)
throws Exception
TestRunnerFacaderunPreTestActionsInEjbContext in interface TestRunnerFacadehandler - TestRunner handler providing information about the test class and methodException - If the actions failpublic void runTestMethodInEjbContext(ch.inftec.ju.ee.test.TestRunnerAnnotationHandler handler)
throws Exception
TestRunnerFacaderunTestMethodInEjbContext in interface TestRunnerFacadehandler - TestRunner handler that provides information about the test class and methodException - If the method fails with an exception (including test assertion failures)public void runPostTestActionsInEjbContext(ch.inftec.ju.ee.test.TestRunnerAnnotationHandler handler)
throws Exception
TestRunnerFacaderunPostTestActionsInEjbContext in interface TestRunnerFacadehandler - TestRunner handler providing information about the test class and methodException - If the actions failpublic Object runMethodInEjbContext(String className, String methodName, Class<?>[] argumentTypes, Object[] args) throws Exception
TestRunnerFacaderunMethodInEjbContext in interface TestRunnerFacadeclassName - Class name that contains the methodmethodName - Method nameargumentTypes - Array of argument typesargs - Array of argumentsExceptionpublic void resetSystemProperties(ch.inftec.ju.util.SystemPropertyTempSetter tempSetter)
TestRunnerFacadeMust be called with the SystemPropertyTempSetter returned by the runPreTestActionInEjbContext method
resetSystemProperties in interface TestRunnerFacadetempSetter - SystemPropertyTempSetter that is used to restore the system property to their original (i.e. pre test)
stateCopyright © 2014. All rights reserved.