test: assert pruned count unconditionally in summary test

Remove the conditional guard on pruned trial assertions since the test
explicitly prunes 2 trials. Assert the expected count first, then check
summary content unconditionally to catch regressions.
This commit is contained in:
Manuel Raimann
2026-02-12 14:19:07 +01:00
parent 271748700f
commit 750bbad0d8
+3 -5
View File
@@ -47,12 +47,10 @@ fn test_summary_with_pruned_trials() {
study.prune_trial(trial);
}
assert_eq!(study.n_pruned_trials(), 2);
let summary = study.summary();
// Should show breakdown when there are pruned trials
if study.n_pruned_trials() > 0 {
assert!(summary.contains("complete"));
assert!(summary.contains("pruned"));
}
assert!(summary.contains("complete"));
assert!(summary.contains("pruned"));
}
#[test]