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

Function TestParseQuWriteFileHelp

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

Source from the content-addressed store, hash-verified

73`
74
75func TestParseQuWriteFileHelp(t *testing.T) {
76 desc, err := ParseHelp([]string{"qu", "--help"}, quWriteFileHelp)
77 require.Nil(t, err)
78
79 expectedContext := datastore.FlagContext{
80 SubCommand: []string{"write-file"},
81 Framework: "argparse",
82 }
83 expected := datastore.HelpPage{
84 ExecutablePath: "qu",
85 Completions: []datastore.Completion{
86 {Flag: "-h", Context: expectedContext},
87 {Flag: "--help", Context: expectedContext},
88 {Flag: "--destination", Context: expectedContext},
89 {Flag: "--compute", Context: expectedContext},
90 },
91 CheckSum: "2fee90df109afb526a5fa229861677497d8baf14",
92 }
93 require.Equal(t, expected, *desc)
94}
95
96var lsHelp = `
97Usage: ls [OPTION]... [FILE]...

Callers

nothing calls this directly

Calls 1

ParseHelpFunction · 0.85

Tested by

no test coverage detected