Package pysys :: Package writer :: Class CSVResultsWriter
[hide private]
[frames] | no frames]

Class CSVResultsWriter

source code

Class to log results to logfile in CSV format.

Writing of the test summary file defaults to the working directory. This can be be over-ridden in the PySys project file using the nested <property> tag on the <writer> tag. The CSV column output is in the form;

id, title, cycle, startTime, duration, outcome

Instance Methods [hide private]
 
__init__(self, logfile)
Create an instance of the TextResultsWriter class.
source code
 
setup(self, **kwargs)
Implementation of the setup method.
source code
 
cleanup(self, **kwargs)
Implementation of the cleanup method.
source code
 
processResult(self, testObj, **kwargs)
Implementation of the processResult method.
source code
Instance Variables [hide private]
string outputDir = None
Path to output directory to write the test summary files
Method Details [hide private]

__init__(self, logfile)
(Constructor)

source code 

Create an instance of the TextResultsWriter class.

Parameters:
  • logfile - The filename template for the logging of test results

setup(self, **kwargs)

source code 

Implementation of the setup method.

Creates the file handle to the logfile and logs initial details of the date, platform and test host.

Parameters:
  • kwargs - Variable argument list

cleanup(self, **kwargs)

source code 

Implementation of the cleanup method.

Flushes and closes the file handle to the logfile.

Parameters:
  • kwargs - Variable argument list

processResult(self, testObj, **kwargs)

source code 

Implementation of the processResult method.

Writes the test id and outcome to the logfile.

Parameters: