fix(internal/parsers/clang_tidy/score.go): slightly fix the output format
All checks were successful
continuous-integration/drone/push Build is passing
continuous-integration/drone/pr Build is passing

This commit is contained in:
张佳澈520370910044 2024-05-05 21:44:47 +08:00
parent 061664eb70
commit 430662daca
2 changed files with 2 additions and 3 deletions

@ -1 +1 @@
Subproject commit bb8c33dc62742f7fc9f25ac91582fc4fa4ac3d5d Subproject commit 422868c1c6427ce73e665477b40922c72ccc14e5

View File

@ -30,7 +30,7 @@ func get_score(json_messages []json_message, conf Conf) int {
} }
func get_comment(json_messages []json_message) string { func get_comment(json_messages []json_message) string {
res := "```\n### Test results summary\n\n" res := "### Test results summary\n\n"
keys := [...]string{ keys := [...]string{
"codequality-unchecked-malloc-result", "codequality-unchecked-malloc-result",
"codequality-no-global-variables", "codequality-no-global-variables",
@ -72,6 +72,5 @@ func get_comment(json_messages []json_message) string {
for i, key := range keys { for i, key := range keys {
res = fmt.Sprintf("%s%d. %s: %d\n", res, i+1, key, mapping[key]) res = fmt.Sprintf("%s%d. %s: %d\n", res, i+1, key, mapping[key])
} }
res += "```"
return res return res
} }