(t *testing.T)
| 15 | } |
| 16 | |
| 17 | func TestAddCommand(t *testing.T) { |
| 18 | cmd := newCmd("root", "") |
| 19 | assert.Equal(t, len(cmd.Children()), 0, "should be empty") |
| 20 | cmd.AddCmd(newCmd("child", "")) |
| 21 | assert.Equal(t, len(cmd.Children()), 1, "should include one child command") |
| 22 | } |
| 23 | |
| 24 | func TestDeleteCommand(t *testing.T) { |
| 25 | cmd := newCmd("root", "") |