(t *testing.T)
| 14 | ) |
| 15 | |
| 16 | func TestSearchCmd_CommandStructure(t *testing.T) { |
| 17 | // Cleanup. |
| 18 | dirs.RemoveAllForTest() |
| 19 | |
| 20 | // Test command creation |
| 21 | search := &searchCmd{} |
| 22 | celer := &configs.Celer{} |
| 23 | |
| 24 | cmd := search.Command(celer) |
| 25 | if cmd.Use != "search" { |
| 26 | t.Errorf("Expected Use to be 'search', got %s", cmd.Use) |
| 27 | } |
| 28 | |
| 29 | if cmd.Short == "" { |
| 30 | t.Error("Short description should not be empty") |
| 31 | } |
| 32 | |
| 33 | if cmd.Long == "" { |
| 34 | t.Error("Long description should not be empty") |
| 35 | } |
| 36 | |
| 37 | // Test Args validation - should require exactly 1 argument. |
| 38 | if cmd.Args == nil { |
| 39 | t.Error("Args validation should be set") |
| 40 | } |
| 41 | } |
| 42 | |
| 43 | func TestSearchCmd_Search_ExactMatch(t *testing.T) { |
| 44 | // Cleanup. |
nothing calls this directly
no test coverage detected