Skip to content

Commit 2bdd229

Browse files
authored
Update README.md
1 parent 68d1922 commit 2bdd229

File tree

1 file changed

+10
-21
lines changed

1 file changed

+10
-21
lines changed

community-reports/cobra-report/README.md

Lines changed: 10 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,8 @@
1-
```markdown
21
# Template Name: cobra-report
32

43
## Description
54

6-
The **cobra-report** template is designed for the COBRA Toolbox to provide a concise overview of your test suite results. It displays key metrics including the total number of tests, passed tests, failed tests, and skipped tests. Additionally, when failures occur, it renders a detailed table listing each failed test along with its failure message.
5+
The **cobra-report** template is designed to provide a concise overview of your test suite results. It displays key metrics including the total number of tests, passed tests, failed tests, and skipped tests. Additionally, when failures occur, it renders a detailed table listing each failed test along with its failure message. If there are no failing tests, the template will render **No failed tests 🎉** instead of the failed tests table
76

87
---
98

@@ -41,38 +40,28 @@ Ensure your report JSON files are generated correctly and placed in the expected
4140

4241
| **Tests 📝** | **Passed ✅** | **Failed ❌** | **Skipped ⏭️** |
4342
| --- | --- | --- | --- |
44-
| {{ctrf.summary.tests}} | {{ctrf.summary.passed}} | {{ctrf.summary.failed}} | {{ctrf.summary.skipped}} |
43+
| 5 | 3 | 1 | 1 |
44+
45+
### ❌ Some tests failed!
4546

46-
### Failed Tests Details
4747

48-
{{#if (anyFailedTests ctrf.tests)}}
4948
<table>
5049
<thead>
5150
<tr>
52-
<th>Failed Tests {{getCtrfEmoji "failed"}}</th>
51+
<th>Failed Tests </th>
5352
<th>Fail Message</th>
5453
</tr>
5554
</thead>
5655
<tbody>
57-
{{#each ctrf.tests}}
58-
{{#if (eq status "failed")}}
5956
<tr>
60-
<td>{{getCtrfEmoji "failed"}} {{name}}</td>
57+
<td>test 1</td>
6158
<td>
62-
{{#if message}}
63-
{{~{formatMessage message}}}
64-
{{else}}
65-
No failure message
66-
{{/if}}
59+
error message!
6760
</td>
6861
</tr>
69-
{{/if}}
70-
{{/each}}
7162
</tbody>
7263
</table>
73-
{{else}}
74-
<p>No failed tests ✨</p>
75-
{{/if}}
7664

77-
This template provides a streamlined and effective overview of your testing performance, making it easy to identify issues and monitor overall progress.
78-
```
65+
### OR
66+
67+
### No failed tests 🎉

0 commit comments

Comments
 (0)