"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "Cheetah/Tests/xmlrunner.py" between
cheetah3-3.1.0.tar.gz and cheetah3-3.2.0.tar.gz

About: Cheetah3 is a template engine and code generation tool for e.g. for Web development or Java, SQL, LaTeX, form email ... (written in Python).

xmlrunner.py  (cheetah3-3.1.0):xmlrunner.py  (cheetah3-3.2.0)
skipping to change at line 60 skipping to change at line 60
self._print_error(stream, 'error', self._error) self._print_error(stream, 'error', self._error)
stream.write('</testcase>\n') stream.write('</testcase>\n')
def _print_error(self, stream, tagname, error): def _print_error(self, stream, tagname, error):
"""Print information from a failure or error to the supplied stream.""" """Print information from a failure or error to the supplied stream."""
text = escape(str(error[1])) text = escape(str(error[1]))
stream.write('\n') stream.write('\n')
stream.write( stream.write(
' <%s type="%s">%s\n' ' <%s type="%s">%s\n'
% (tagname, % (tagname,
issubclass(error[0], Exception) and issubclass(error[0], Exception)
error[0].__name__ or str(error[0]), text)) and error[0].__name__ or str(error[0]), text))
tb_stream = StringIO() tb_stream = StringIO()
traceback.print_tb(error[2], None, tb_stream) traceback.print_tb(error[2], None, tb_stream)
stream.write(escape(tb_stream.getvalue())) stream.write(escape(tb_stream.getvalue()))
stream.write(' </%s>\n' % tagname) stream.write(' </%s>\n' % tagname)
stream.write(' ') stream.write(' ')
# Module level functions since Python 2.3 doesn't grok decorators # Module level functions since Python 2.3 doesn't grok decorators
def create_success(test, time): def create_success(test, time):
"""Create a _TestInfo instance for a successful test.""" """Create a _TestInfo instance for a successful test."""
 End of changes. 1 change blocks. 
2 lines changed or deleted 2 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)