(t *testing.T)
| 274 | } |
| 275 | |
| 276 | func TestTracks_BlockedExcluded(t *testing.T) { |
| 277 | tmpDir := createTracksTestTaskFiles(t) |
| 278 | resetTracksFlags() |
| 279 | tracksFormat = "json" |
| 280 | |
| 281 | output, err := captureTracksOutput(t, []string{tmpDir}) |
| 282 | if err != nil { |
| 283 | t.Fatalf("runTracks failed: %v", err) |
| 284 | } |
| 285 | |
| 286 | var result tracks.Result |
| 287 | if err := json.Unmarshal([]byte(output), &result); err != nil { |
| 288 | t.Fatalf("Failed to parse JSON: %v", err) |
| 289 | } |
| 290 | |
| 291 | // Task 006 depends on 007 (pending) -> blocked. |
| 292 | for _, track := range result.Tracks { |
| 293 | for _, task := range track.Tasks { |
| 294 | if task.ID == "006" { |
| 295 | t.Error("Blocked task 006 should not appear in tracks") |
| 296 | } |
| 297 | } |
| 298 | } |
| 299 | for _, task := range result.Flexible { |
| 300 | if task.ID == "006" { |
| 301 | t.Error("Blocked task 006 should not appear in flexible") |
| 302 | } |
| 303 | } |
| 304 | } |
| 305 | |
| 306 | func TestTracks_FlexibleTasks(t *testing.T) { |
| 307 | tmpDir := createTracksTestTaskFiles(t) |
nothing calls this directly
no test coverage detected