org.aitools.programd.test.aiml
Class TestReport

java.lang.Object
  extended by org.aitools.programd.test.aiml.TestReport

public class TestReport
extends java.lang.Object

Contains a list of test successes and failures, and can generate a report about them.

Author:
Noel Bush

Field Summary
private  java.util.LinkedList<TestResult> failures
          The test failures.
private  java.util.LinkedList<TestResult> successes
          The test successes.
 
Constructor Summary
TestReport(java.util.LinkedList<TestResult> reportedSuccesses, java.util.LinkedList<TestResult> reportedFailures)
          Creates a new TestReport with the given reported successes and failures.
 
Method Summary
 void logSummary(org.apache.log4j.Logger logger)
          Prints a summary of the test report to the given logger.
 void write(java.lang.String path)
          Writes a report to the given filename.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

successes

private java.util.LinkedList<TestResult> successes
The test successes.


failures

private java.util.LinkedList<TestResult> failures
The test failures.

Constructor Detail

TestReport

public TestReport(java.util.LinkedList<TestResult> reportedSuccesses,
                  java.util.LinkedList<TestResult> reportedFailures)
Creates a new TestReport with the given reported successes and failures.

Parameters:
reportedSuccesses - the successes
reportedFailures - the failures
Method Detail

logSummary

public void logSummary(org.apache.log4j.Logger logger)
Prints a summary of the test report to the given logger.

Parameters:
logger - the logger to which to print the summary

write

public void write(java.lang.String path)
Writes a report to the given filename.

Parameters:
path - the path to which to write the report