79 lines
1.3 KiB
Cheetah
79 lines
1.3 KiB
Cheetah
|
# Test report
|
||
|
{{range .Suites}}
|
||
|
## {{ .Name }}
|
||
|
|
||
|
### Overview
|
||
|
|
||
|
| State | Total |
|
||
|
|-------|-------|
|
||
|
| Passed | {{ .Totals.Passed }} |
|
||
|
| Skipped | {{ .Totals.Skipped }} |
|
||
|
| Failed | {{ .Totals.Failed }} |
|
||
|
| Error | {{ .Totals.Error }} |
|
||
|
|
||
|
**Total duration**: {{ .Totals.Duration }}
|
||
|
|
||
|
### Details
|
||
|
|
||
|
| Status | Name | Class |
|
||
|
|--------|------|-------|
|
||
|
{{- range .Tests }}
|
||
|
| {{ template "status_icon" .Status }} | `{{ .Name }}` ||
|
||
|
{{- end -}}
|
||
|
{{- range .Suites }}
|
||
|
{{- $suite := . }}
|
||
|
{{- range .Tests }}
|
||
|
| {{ template "status_icon" .Status }} | `{{ .Name }}` | `{{ $suite.Name }}` |
|
||
|
{{- end -}}
|
||
|
{{end}}
|
||
|
|
||
|
{{if or (gt .Totals.Error 0) (gt .Totals.Failed 0) }}
|
||
|
#### Errors
|
||
|
{{end}}
|
||
|
|
||
|
{{- range .Tests }}
|
||
|
{{ if or ( eq .Status "error" ) (eq .Status "failed" ) }}
|
||
|
<details>
|
||
|
<summary>`{{ .Name -}}`</summary>
|
||
|
|
||
|
**Output**
|
||
|
|
||
|
```
|
||
|
{{ .Error -}}
|
||
|
```
|
||
|
|
||
|
</details>
|
||
|
{{ end }}
|
||
|
{{- end -}}
|
||
|
{{- range .Suites }}
|
||
|
{{- $suite := . }}
|
||
|
{{- range .Tests }}
|
||
|
{{ if or ( eq .Status "error" ) (eq .Status "failed" ) }}
|
||
|
<details>
|
||
|
<summary>`{{ .Name -}}`</summary>
|
||
|
|
||
|
**Suite**
|
||
|
|
||
|
```
|
||
|
{{ $suite.Name }}
|
||
|
```
|
||
|
|
||
|
**Output**
|
||
|
|
||
|
```
|
||
|
{{ .Error -}}
|
||
|
```
|
||
|
</details>
|
||
|
|
||
|
{{ end }}
|
||
|
{{- end -}}
|
||
|
{{end}}
|
||
|
|
||
|
|
||
|
{{end -}}
|
||
|
|
||
|
{{define "status_icon"}}
|
||
|
{{- if eq . "passed" -}}✓{{- end -}}
|
||
|
{{- if or (eq . "error") (eq . "failed") -}}⨯{{- end -}}
|
||
|
{{- if eq . "skipped" -}}⏩{{- end -}}
|
||
|
{{end}}
|