(t *testing.T)
| 344 | } |
| 345 | |
| 346 | func TestRunStatus_DuplicateIDError(t *testing.T) { |
| 347 | tmpDir := createDuplicateTestFiles(t) |
| 348 | statusFormat = "text" |
| 349 | statusExact = false |
| 350 | statusThreshold = 0.6 |
| 351 | statusMinimal = false |
| 352 | statusStatusline = false |
| 353 | statusScope = "" |
| 354 | taskDir = tmpDir |
| 355 | |
| 356 | err := runStatusSingle("042") |
| 357 | if err == nil { |
| 358 | t.Fatal("expected error for duplicate ID, got nil") |
| 359 | } |
| 360 | if !strings.Contains(err.Error(), "duplicate task ID") { |
| 361 | t.Errorf("expected 'duplicate task ID' error, got: %v", err) |
| 362 | } |
| 363 | if !strings.Contains(err.Error(), "042") { |
| 364 | t.Errorf("expected error to mention ID 042, got: %v", err) |
| 365 | } |
| 366 | } |
| 367 | |
| 368 | func TestRunSet_DuplicateIDError(t *testing.T) { |
| 369 | tmpDir := createDuplicateTestFiles(t) |
nothing calls this directly
no test coverage detected