aboutsummaryrefslogtreecommitdiffstats
path: root/dashboard
diff options
context:
space:
mode:
authorTaras Madan <tarasmadan@google.com>2024-12-12 11:47:53 +0100
committerTaras Madan <tarasmadan@google.com>2024-12-12 11:54:56 +0000
commit1b70f4d9b27d13db53fd31d516a5a4bdcedf1210 (patch)
treef540a91b40e8c9ac0a73f088e544c9edc03f6633 /dashboard
parent996b12733ae74ca4cdefabe40e7ec16b3ca7452a (diff)
dashboard/app: fix total coverage visualization
Diffstat (limited to 'dashboard')
-rw-r--r--dashboard/app/graphs.go6
1 files changed, 4 insertions, 2 deletions
diff --git a/dashboard/app/graphs.go b/dashboard/app/graphs.go
index 2b4ab15ca..5625b919e 100644
--- a/dashboard/app/graphs.go
+++ b/dashboard/app/graphs.go
@@ -333,9 +333,11 @@ func handleCoverageGraph(c context.Context, w http.ResponseWriter, r *http.Reque
if _, ok := hist.covered[date]; !ok || hist.instrumented[date] == 0 {
cols = append(cols, uiGraphColumn{Hint: date, Vals: []uiGraphValue{{IsNull: true}}})
} else {
+ val := float32(hist.covered[date]) / float32(hist.instrumented[date])
cols = append(cols, uiGraphColumn{
- Vals: []uiGraphValue{{Val: float32(hist.covered[date]) / float32(hist.instrumented[date])}},
- Hint: date,
+ Hint: date,
+ Annotation: val,
+ Vals: []uiGraphValue{{Val: val}},
})
}
}