MCPcopy Create free account
hub / github.com/dim-an/cod / TestParseCatHelp

Function TestParseCatHelp

parse_doc/parse_help_test.go:42–57  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

40`
41
42func TestParseCatHelp(t *testing.T) {
43 desc, err := ParseHelp([]string{"cat", "--help"}, catHelp)
44 require.Nil(t, err)
45
46 expected := datastore.HelpPage{
47 ExecutablePath: "cat",
48 Completions: []datastore.Completion{
49 {Flag: "-A"},
50 {Flag: "--show-all"},
51 {Flag: "-e"},
52 {Flag: "--help"},
53 },
54 CheckSum: "4a8d01dde2483ad006b8f5ac2f599f9369287730",
55 }
56 require.Equal(t, expected, *desc)
57}
58
59var quWriteFileHelp = `
60usage: qu write-file [-h] [--destination DESTINATION]

Callers

nothing calls this directly

Calls 1

ParseHelpFunction · 0.85

Tested by

no test coverage detected