brew-test-bot: regex to delete invalid XML chars.

This commit is contained in:
Mike McQuaid 2013-12-18 09:39:58 +00:00
parent 8a2464bf25
commit d03100c615

View File

@ -473,7 +473,7 @@ if ARGV.include? "--junit"
failure = testcase.add_element 'failure' if step.failed?
if step.has_output?
# Remove invalid XML CData characters from step output.
output = REXML::CData.new step.output.delete("\000\00c\e")
output = REXML::CData.new step.output.gsub(/\000\00c\e/, '')
if step.passed?
system_out = testcase.add_element 'system-out'
system_out.text = output