diff --git a/src/main/resources/report/partials/dashboard.html b/src/main/resources/report/partials/dashboard.html
index 6481345..b5f06a3 100644
--- a/src/main/resources/report/partials/dashboard.html
+++ b/src/main/resources/report/partials/dashboard.html
@@ -59,7 +59,7 @@
+
diff --git a/src/main/resources/report/report.js b/src/main/resources/report/report.js
index 23e8b64..214f128 100644
--- a/src/main/resources/report/report.js
+++ b/src/main/resources/report/report.js
@@ -118,7 +118,12 @@ if (window.Chart && trendData.length >= 2) {
});
line('trendRateChart', 'Pass rate (%)', trendData.map(r => r.passRate), color('--good'), 100);
line('trendTimeChart', 'Duration (s)', trendData.map(r => r.durationSec), color('--primary'));
- line('trendFlakyChart', 'Flaky tests', trendData.map(r => r.flakyTests), color('--warn'));
+ // Hide the flaky card entirely when no run in the history had flaky tests.
+ if (trendData.some(r => r.flakyTests > 0)) {
+ line('trendFlakyChart', 'Flaky tests', trendData.map(r => r.flakyTests), color('--warn'));
+ } else {
+ document.getElementById('trendFlakyCard').style.display = 'none';
+ }
}
// ── Collapse / expand class groups ──