Python 3 support (#212)

This commit is contained in:
Markus Grimm 2019-03-26 19:26:59 +01:00 committed by Dirk Thomas
parent 9ae30ba95a
commit 79d07b53e0
1 changed files with 3 additions and 3 deletions

View File

@ -104,14 +104,14 @@ class XmlResultTestGeneration(unittest.TestCase):
def testGenerateError(self):
error = junitxml.TestError('error_type', 'error_text')
error_str = error.xml()
self.assertEquals('''<error type="error_type">&lt;![CDATA[
self.assertEquals(b'''<error type="error_type">&lt;![CDATA[
error_text
]]&gt;</error>''', error_str)
def testGenerateFailure(self):
failure = junitxml.TestFailure('failure_type', 'failure_text')
failure_str = failure.xml()
self.assertEquals('''<failure type="failure_type">&lt;![CDATA[
self.assertEquals(b'''<failure type="failure_type">&lt;![CDATA[
failure_text
]]&gt;</failure>''', failure_str)
@ -124,7 +124,7 @@ failure_text
testcase.add_error(error)
testcase.add_failure(failure)
testcase_str = testcase.xml()
self.assertEquals('''<testcase classname="" name="test_case" time="0.0"><failure type="failure_type">&lt;![CDATA[
self.assertEquals(b'''<testcase classname="" name="test_case" time="0.0"><failure type="failure_type">&lt;![CDATA[
failure_text
]]&gt;</failure><error type="error_type">&lt;![CDATA[
error_text