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

Function Test_ShowRootCommandHelp_HideVersion

help_test.go:41–52  ·  help_test.go::Test_ShowRootCommandHelp_HideVersion
(t *testing.T)

Source from the content-addressed store, hash-verified

39}
40
41func Test_ShowRootCommandHelp_HideVersion(t *testing.T) {
42 output := new(bytes.Buffer)
43 cmd := &Command{Writer: output}
44
45 cmd.HideVersion = true
46
47 _ = ShowRootCommandHelp(cmd)
48
49 if bytes.Contains(output.Bytes(), []byte("VERSION:")) {
50 t.Errorf("expected\n%snot to include %s", output.String(), "VERSION:")
51 }
52}
53
54func Test_ShowRootCommandHelp_MultiLineDescription(t *testing.T) {
55 output := new(bytes.Buffer)

Callers

nothing calls this directly

Calls 1

StringMethod · 0.45

Tested by

no test coverage detected