Package org.apache.jackrabbit.test
Class JCRTestResult
- java.lang.Object
-
- junit.framework.TestResult
-
- org.apache.jackrabbit.test.JCRTestResult
-
public class JCRTestResult extends junit.framework.TestResult
Extends the standard JUnit TestResult class. This class ignores test errors that originated in throwing aNotExecutableException
.
-
-
Constructor Summary
Constructors Constructor Description JCRTestResult(junit.framework.TestResult orig, LogPrintWriter log)
Creates a new JCRTestResult that delegates toorig
.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addError(junit.framework.Test test, Throwable throwable)
Only add an error ifthrowable
is not of typeNotExecutableException
and the test case is not a known issue.void
addFailure(junit.framework.Test test, junit.framework.AssertionFailedError assertionFailedError)
Only adds a failure iftest
is not a known issue.void
addListener(junit.framework.TestListener testListener)
void
endTest(junit.framework.Test test)
int
errorCount()
Enumeration<junit.framework.TestFailure>
errors()
int
failureCount()
Enumeration<junit.framework.TestFailure>
failures()
void
removeListener(junit.framework.TestListener testListener)
protected void
run(junit.framework.TestCase test)
int
runCount()
boolean
shouldStop()
void
startTest(junit.framework.Test test)
void
stop()
boolean
wasSuccessful()
-
-
-
Constructor Detail
-
JCRTestResult
public JCRTestResult(junit.framework.TestResult orig, LogPrintWriter log)
Creates a new JCRTestResult that delegates toorig
.- Parameters:
orig
- the original TestResult this result wraps.log
- the logger
-
-
Method Detail
-
run
protected void run(junit.framework.TestCase test)
- Overrides:
run
in classjunit.framework.TestResult
-
addError
public void addError(junit.framework.Test test, Throwable throwable)
Only add an error ifthrowable
is not of typeNotExecutableException
and the test case is not a known issue.- Overrides:
addError
in classjunit.framework.TestResult
- Parameters:
test
- the test.throwable
- the exception thrown by the test.
-
addFailure
public void addFailure(junit.framework.Test test, junit.framework.AssertionFailedError assertionFailedError)
Only adds a failure iftest
is not a known issue.- Overrides:
addFailure
in classjunit.framework.TestResult
- Parameters:
test
- the test case that failed.assertionFailedError
- the assertion error.
-
addListener
public void addListener(junit.framework.TestListener testListener)
- Overrides:
addListener
in classjunit.framework.TestResult
-
removeListener
public void removeListener(junit.framework.TestListener testListener)
- Overrides:
removeListener
in classjunit.framework.TestResult
-
endTest
public void endTest(junit.framework.Test test)
- Overrides:
endTest
in classjunit.framework.TestResult
-
errorCount
public int errorCount()
- Overrides:
errorCount
in classjunit.framework.TestResult
-
errors
public Enumeration<junit.framework.TestFailure> errors()
- Overrides:
errors
in classjunit.framework.TestResult
-
failureCount
public int failureCount()
- Overrides:
failureCount
in classjunit.framework.TestResult
-
failures
public Enumeration<junit.framework.TestFailure> failures()
- Overrides:
failures
in classjunit.framework.TestResult
-
runCount
public int runCount()
- Overrides:
runCount
in classjunit.framework.TestResult
-
shouldStop
public boolean shouldStop()
- Overrides:
shouldStop
in classjunit.framework.TestResult
-
startTest
public void startTest(junit.framework.Test test)
- Overrides:
startTest
in classjunit.framework.TestResult
-
stop
public void stop()
- Overrides:
stop
in classjunit.framework.TestResult
-
wasSuccessful
public boolean wasSuccessful()
- Overrides:
wasSuccessful
in classjunit.framework.TestResult
-
-