Fix null check to work with assertEqual-failures and exception messages containing reserved xml characters

This commit is contained in:
Marcus Svartmark 2017-11-09 16:32:35 +01:00
parent c25417e702
commit 017dfcbff8

View File

@ -1,25 +1,25 @@
<?xml version="1.0" encoding="UTF-8"?>
<response>
<test>${test?html}</test>
<result>${result?html}</result>
<test>${test?xml}</test>
<result>${result?xml}</result>
<#if failures??>
<failures>
<#list failures as failure>
<trace>${failure.getTrace()?html}</trace>
<exception>${failure.getException()?html}</exception>
<message>${failure.getMessage()!""?html}</message>
<testHeader>${failure.getTestHeader()?html}</testHeader>
<trace>${failure.getTrace()?xml}</trace>
<exception>${failure.getException()?xml}</exception>
<message>${failure.getMessage()!?xml}</message>
<testHeader>${failure.getTestHeader()?xml}</testHeader>
</#list>
</failures>
</#if>
<failureCount>${failureCount?html}</failureCount>
<ignoreCount>${ignoreCount?html}</ignoreCount>
<runCount>${runCount?html}</runCount>
<runTime>${runTime?html}</runTime>
<failureCount>${failureCount?xml}</failureCount>
<ignoreCount>${ignoreCount?xml}</ignoreCount>
<runCount>${runCount?xml}</runCount>
<runTime>${runTime?xml}</runTime>
<#if throwables??>
<throwables>
<#list throwables as throwable>
<throwable>${throwable?html}</throwable>
<throwable>${throwable?xml}</throwable>
</#list>
</throwables>
</#if>