
{# 
   This template requires you to define or pass in the variable test_list
   to be a list of dictionaries with keys of name, setup, call, teardown
   describing results of tests. Only items with outcome == 'failed' will
   be displayed.
#}
<details open>
  <summary>
    <b>Failures</b>
  </summary>
  {% set failure_num = 0 %}	
  {% for item in test_list %}
  {% if item.outcome == 'failed' %}
  {# For this to look right on github, need no spaces before tags #}
<!-- *IMPORTANT*: to look right on github, need no spaces before tags -->
<details class="w3-red">{% set failure_num = failure_num + 1 %}
<summary>{{('%i'%failure_num).zfill(3)}} -- {{ item.name }}</summary>
{% for piece in ['setup', 'call', 'teardown'] %}
{% if item[piece].outcome == 'failed' %}
<br>
<PRE>
{{ item[piece].longrepr }}
</PRE>
<br>
{% endif %}
{% endfor %}
</details>
{% else %}
{% endif %}
{% endfor %}
</details>


{# 
   This template requires you to define or pass in the variable test_list
   to be a list of dictionaries with keys of name, setup, call, teardown
   describing results of tests. Only items with outcome == 'failed' will
   be displayed.
#}
<details open>
  <summary>
    <b>Failures</b>
  </summary>
  {% set failure_num = 0 %}	
  {% for item in test_list %}
  {% if item.error %}
  {# For this to look right on github, need no spaces before tags #}
<!-- *IMPORTANT*: to look right on github, need no spaces before tags -->
<details class="w3-red">{% set failure_num = failure_num + 1 %}
<summary>{{('%i'%failure_num).zfill(3)}} -- {{ item['@name'] }}</summary>
<br>
{% if item['error']['#text'] %}
<PRE>
{{ item['error']['#text'] }}
</PRE>
{% else %}
{% set thing_num = 0 %}	
{% for thing in item['error'] %}
{% set thing_num = thing_num + 1 %}
<div style="margin-left: 2%;">
<details open><summary> Sub-failure {{ ('%i'%thing_num).zfill(3) }}</summary>
<PRE>
{{ thing['#text'] }}
</PRE>
</details>
</div>
{% endfor %}
{% endif %}
<br>
</details>
{% else %}
{% endif %}
{% endfor %}
</details>

Change display to work on github and use new xml format
Change display to work on github and use new xml format
