(t *testing.T)
| 320 | } |
| 321 | |
| 322 | func TestRunStats_PhaseShownWhenPresent(t *testing.T) { |
| 323 | tmpDir := createStatsPhaseTestFiles(t) |
| 324 | resetStatsFlags() |
| 325 | // No --group-by flag, but tasks have phases — section should still appear |
| 326 | |
| 327 | output, err := captureStatsOutput(t, []string{tmpDir}) |
| 328 | if err != nil { |
| 329 | t.Fatalf("runStats failed: %v", err) |
| 330 | } |
| 331 | |
| 332 | if !strings.Contains(output, "BY PHASE:") { |
| 333 | t.Errorf("expected BY PHASE section when phases exist:\n%s", output) |
| 334 | } |
| 335 | } |
nothing calls this directly
no test coverage detected