─── NewViewCommand ───────────────────────────────────────────────────────────
(t *testing.T)
| 15 | // ─── NewViewCommand ─────────────────────────────────────────────────────────── |
| 16 | |
| 17 | func TestNewViewCommand_FlagsExist(t *testing.T) { |
| 18 | cmd := NewViewCommand() |
| 19 | if cmd == nil { |
| 20 | t.Fatal("NewViewCommand returned nil") |
| 21 | } |
| 22 | |
| 23 | for _, name := range []string{"output", "repo"} { |
| 24 | if cmd.Flags().Lookup(name) == nil && cmd.InheritedFlags().Lookup(name) == nil { |
| 25 | t.Errorf("expected flag --%s to be defined", name) |
| 26 | } |
| 27 | } |
| 28 | } |
| 29 | |
| 30 | func TestNewViewCommand_UseAndShort(t *testing.T) { |
| 31 | cmd := NewViewCommand() |
nothing calls this directly
no test coverage detected