(t *testing.T)
| 261 | } |
| 262 | |
| 263 | func TestRunStats_GroupByPhase_Table(t *testing.T) { |
| 264 | tmpDir := createStatsPhaseTestFiles(t) |
| 265 | resetStatsFlags() |
| 266 | statsGroupBy = "phase" |
| 267 | |
| 268 | output, err := captureStatsOutput(t, []string{tmpDir}) |
| 269 | if err != nil { |
| 270 | t.Fatalf("runStats failed: %v", err) |
| 271 | } |
| 272 | |
| 273 | if !strings.Contains(output, "BY PHASE:") { |
| 274 | t.Errorf("expected BY PHASE section in output:\n%s", output) |
| 275 | } |
| 276 | if !strings.Contains(output, "v0.2:") { |
| 277 | t.Errorf("expected v0.2 phase in output:\n%s", output) |
| 278 | } |
| 279 | if !strings.Contains(output, "v0.3:") { |
| 280 | t.Errorf("expected v0.3 phase in output:\n%s", output) |
| 281 | } |
| 282 | } |
| 283 | |
| 284 | func TestRunStats_GroupByPhase_JSON(t *testing.T) { |
| 285 | tmpDir := createStatsPhaseTestFiles(t) |
nothing calls this directly
no test coverage detected