From d1386a88dd1654f79544e93b03985b8700a3dbea Mon Sep 17 00:00:00 2001 From: Chris Matthews Date: Fri, 11 May 2018 18:38:02 +0000 Subject: [PATCH] [LIT] replace output escapes wit a cdata block CDATA blocks don't need to have XML stuff escaped. Makes sense to wrap output in them instead of escaping. llvm-svn: 332116 --- llvm/utils/lit/lit/Test.py | 6 +++--- llvm/utils/lit/tests/xunit-output.py | 4 +--- 2 files changed, 4 insertions(+), 6 deletions(-) diff --git a/llvm/utils/lit/lit/Test.py b/llvm/utils/lit/lit/Test.py index 1a454929..c6ab505 100644 --- a/llvm/utils/lit/lit/Test.py +++ b/llvm/utils/lit/lit/Test.py @@ -376,9 +376,9 @@ class Test: testcase_xml = testcase_template.format(class_name=class_name, test_name=test_name, time=elapsed_time) fil.write(testcase_xml) if self.result.code.isFailure: - fil.write(u">\n\t\n") - fil.write(escape(self.result.output)) - fil.write(u"\n\t\n") + fil.write(u">\n\t\n") elif self.result.code == UNSUPPORTED: fil.write(u">\n\t\n\n") else: diff --git a/llvm/utils/lit/tests/xunit-output.py b/llvm/utils/lit/tests/xunit-output.py index 965a01c..352f67e 100644 --- a/llvm/utils/lit/tests/xunit-output.py +++ b/llvm/utils/lit/tests/xunit-output.py @@ -6,8 +6,6 @@ # CHECK: # CHECK: # CHECK: -# CHECK-NEXT: -# CHECK-NEXT:& < > " -# CHECK-NEXT: +# CHECK-NEXT: "]]> # CHECK: # CHECK: -- 2.7.4