3
3
This template contains the format for an individual package. GitHub actions does not currently support nested groups so
4
4
we are creating a stylized header for each package.
5
5
*/ -}}
6
- {{- "\033" }}[0Ksection_start:{{ with .StartTime }}{{ .Unix }}{{ else }}0{{ end }}:{{ .ID }}{{ "\r\033" }}[0K
7
- {{- if eq .Result "PASS" -}}
8
- {{- "\033" }}[0;32m
9
- {{- else if eq .Result "SKIP" -}}
10
- {{- "\033" }}[0;33m
11
- {{- else -}}
12
- {{- "\033" }}[0;31m
13
- {{- end -}}
14
- 📦 {{ .Name }}{{ "\033" }}[0m{{- "\n" -}}
15
- {{- with .Reason }}
16
- 🛑 {{ . -}}{{- "\n" -}}
17
- {{- end -}}
18
- {{- with .Output -}}
19
- {{- . -}}{{- "\n" -}}
20
- {{- end -}}
21
- {{- with .TestCases -}}
22
- {{- range . -}}
23
- {{- "\033[0K" }}section_start:{{ with .StartTime }}{{ .Unix }}{{ else }}0{{ end }}:{{ .ID }}[collapsed=true]{{- "\r\033[0K" -}}
24
- {{- if eq .Result "PASS" -}}
25
- {{- "\033[0;32m " }}✅
26
- {{- else if eq .Result "SKIP" -}}
27
- {{- "\033[0;33m " }}🚧
28
- {{- else -}}
29
- {{- "\033[0;31m " }}❌
30
- {{- end -}}
31
- {{- " " }}{{- .Name -}}
32
- {{- with .Coverage -}}{{- " \033" -}}[0;37m (coverage: {{ . }}%){{- end -}}
33
- {{- "\033" -}}[0m
34
- {{- "\n" -}}
6
+ {{- $settings := .Settings -}}
7
+ {{- if and (or (not $settings.HideSuccessfulPackages) (ne .Result "PASS")) (or (not $settings.HideEmptyPackages) (ne .Result "SKIP") (ne (len .TestCases) 0)) -}}
8
+ {{- "\033" }}[0Ksection_start:{{ with .StartTime }}{{ .Unix }}{{ else }}0{{ end }}:{{ .ID }}{{ "\r\033" }}[0K
9
+ {{- if eq .Result "PASS" -}}
10
+ {{- "\033" }}[0;32m
11
+ {{- else if eq .Result "SKIP" -}}
12
+ {{- "\033" }}[0;33m
13
+ {{- else -}}
14
+ {{- "\033" }}[0;31m
15
+ {{- end -}}
16
+ 📦 {{ .Name }}{{ "\033" }}[0m{{- "\n" -}}
17
+ {{- with .Reason -}}
18
+ {{- " " -}}🛑 {{ . -}}{{- "\n" -}}
19
+ {{- end -}}
20
+ {{- with .Output -}}
21
+ {{- . -}}{{- "\n" -}}
22
+ {{- end -}}
23
+ {{- with .TestCases -}}
24
+ {{- range . -}}
25
+ {{- if or (not $settings.HideSuccessfulTests) (ne .Result "PASS") -}}
26
+ {{- "\033[0K" }}section_start:{{ with .StartTime }}{{ .Unix }}{{ else }}0{{ end }}:{{ .ID }}[collapsed=true]{{- "\r\033[0K" -}}
27
+ {{- if eq .Result "PASS" -}}
28
+ {{- "\033[0;32m " }}✅
29
+ {{- else if eq .Result "SKIP" -}}
30
+ {{- "\033[0;33m " }}🚧
31
+ {{- else -}}
32
+ {{- "\033[0;31m " }}❌
33
+ {{- end -}}
34
+ {{- " " }}{{- .Name -}}
35
+ {{- with .Coverage -}}{{- " \033" -}}[0;37m (coverage: {{ . }}%){{- end -}}
36
+ {{- "\033" -}}[0m
37
+ {{- "\n" -}}
35
38
36
- {{- with .Output -}}
37
- {{- . -}}
38
- {{- "\n" -}}
39
- {{- end -}}
39
+ {{- with .Output -}}
40
+ {{- . -}}
41
+ {{- "\n" -}}
42
+ {{- end -}}
40
43
41
- {{- "\033[0K" }}section_end:{{ with .EndTime }}{{ .Unix }}{{ else }}0{{ end }}:{{ .ID }}{{ "\r\033[0K" }}{{- "\n" -}}
44
+ {{- "\033[0K" }}section_end:{{ with .EndTime }}{{ .Unix }}{{ else }}0{{ end }}:{{ .ID }}{{ "\r\033[0K" }}{{- "\n" -}}
45
+ {{- end -}}
46
+ {{- end -}}
42
47
{{- end -}}
43
- {{- end -}}
44
- {{- "\033[0K" }}section_end:{{ with .EndTime }}{{ .Unix }}{{ else }}0{{ end}}:{{ .ID }}{{ "\r\033[0K" }}{{- "\n" -}}
48
+ {{- "\033[0K" }}section_end:{{ with .EndTime }}{{ .Unix }}{{ else }}0{{ end}}:{{ .ID }}{{ "\r\033[0K" }}{{- "\n" -}}
49
+ {{- end -}}
0 commit comments