Package org.testng.junit
Class JUnitTestRunner
java.lang.Object
org.testng.junit.JUnitTestRunner
- All Implemented Interfaces:
junit.framework.TestListener,IJUnitTestRunner
@Deprecated
public class JUnitTestRunner
extends Object
implements junit.framework.TestListener, IJUnitTestRunner
Deprecated.
A JUnit TestRunner that records/triggers all information/events necessary to TestNG.
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate Collection<IInvokedMethodListener> Deprecated.private final List<ITestNGMethod> Deprecated.private final ITestObjectFactoryDeprecated.private final ITestResultNotifierDeprecated.private final Map<junit.framework.Test, JUnitTestRunner.TestRunInfo> Deprecated.static final StringDeprecated. -
Constructor Summary
ConstructorsConstructorDescriptionJUnitTestRunner(ITestObjectFactory objectFactory, ITestResultNotifier tr) Deprecated. -
Method Summary
Modifier and TypeMethodDescriptionvoidDeprecated.voidaddFailure(junit.framework.Test test, junit.framework.AssertionFailedError t) Deprecated.protected junit.framework.TestResultDeprecated.Creates the TestResult to be used for the test run.protected junit.framework.TestResultdoRun(junit.framework.Test suite) Deprecated.voidendTest(junit.framework.Test test) Deprecated.protected junit.framework.TestDeprecated.Returns the Test corresponding to the given suite.Deprecated.Needed from TestRunner in order to figure out what JUnit test methods were run.private voidrecordFailure(junit.framework.Test test, Throwable t) Deprecated.private TestResultrecordResults(junit.framework.Test test, JUnitTestRunner.TestRunInfo tri) Deprecated.voidDeprecated.Astartimplementation that ignores theTestResultprotected voidDeprecated.voidDeprecated.junit.framework.TestResultDeprecated.Starts a test run.voidstartTest(junit.framework.Test test) Deprecated.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.testng.junit.IJUnitTestRunner
setTestResultNotifier
-
Field Details
-
SUITE_METHODNAME
Deprecated.- See Also:
-
m_objectFactory
Deprecated. -
m_parentRunner
Deprecated. -
m_tests
Deprecated. -
m_methods
Deprecated. -
m_invokedMethodListeners
Deprecated.
-
-
Constructor Details
-
JUnitTestRunner
Deprecated.
-
-
Method Details
-
getTestMethods
Deprecated.Needed from TestRunner in order to figure out what JUnit test methods were run.- Specified by:
getTestMethodsin interfaceIJUnitTestRunner- Returns:
- the list of all JUnit test methods run
-
startTest
public void startTest(junit.framework.Test test) Deprecated.- Specified by:
startTestin interfacejunit.framework.TestListener- See Also:
-
addError
Deprecated.- Specified by:
addErrorin interfacejunit.framework.TestListener- See Also:
-
addFailure
public void addFailure(junit.framework.Test test, junit.framework.AssertionFailedError t) Deprecated.- Specified by:
addFailurein interfacejunit.framework.TestListener- See Also:
-
recordFailure
Deprecated. -
endTest
public void endTest(junit.framework.Test test) Deprecated.- Specified by:
endTestin interfacejunit.framework.TestListener- See Also:
-
setInvokedMethodListeners
Deprecated.- Specified by:
setInvokedMethodListenersin interfaceIJUnitTestRunner
-
recordResults
Deprecated. -
getTest
protected junit.framework.Test getTest(Class<? extends junit.framework.Test> testClass, String... methods) Deprecated.Returns the Test corresponding to the given suite. This is a template method, subclasses override runFailed(), clearStatus().- Parameters:
testClass- The test classmethods- The test methods- Returns:
- The corresponding Test
-
run
Deprecated.Astartimplementation that ignores theTestResult- Specified by:
runin interfaceIJUnitTestRunner- Parameters:
testClass- the JUnit test class
-
start
Deprecated.Starts a test run. Analyzes the command line arguments and runs the given test suite.- Parameters:
testCase- The test class to runmethods- The test methods to run- Returns:
- The test result
-
runFailed
Deprecated. -
createTestResult
protected junit.framework.TestResult createTestResult()Deprecated.Creates the TestResult to be used for the test run.- Returns:
- The created test result
-
doRun
protected junit.framework.TestResult doRun(junit.framework.Test suite) Deprecated.
-
7.7.0