MCPcopy
hub / github.com/urfave/cli / TestSetupInitializesBothWriters

Function TestSetupInitializesBothWriters

command_test.go:3208–3215  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

3206}
3207
3208func TestSetupInitializesBothWriters(t *testing.T) {
3209 cmd := &Command{}
3210
3211 cmd.setupDefaults([]string{"test"})
3212
3213 assert.Equal(t, cmd.ErrWriter, os.Stderr, "expected a.ErrWriter to be os.Stderr")
3214 assert.Equal(t, cmd.Writer, os.Stdout, "expected a.Writer to be os.Stdout")
3215}
3216
3217func TestSetupInitializesOnlyNilWriters(t *testing.T) {
3218 wr := &bytes.Buffer{}

Callers

nothing calls this directly

Calls 1

setupDefaultsMethod · 0.95

Tested by

no test coverage detected