|
|
@ -398,8 +398,25 @@ function test.get_entry_short_help()
|
|
|
|
end
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
|
|
function test.get_entry_long_help()
|
|
|
|
function test.get_entry_long_help()
|
|
|
|
|
|
|
|
local expected = [[
|
|
|
|
|
|
|
|
basic
|
|
|
|
|
|
|
|
*****
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
**Tags:** map
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
**Command:**
|
|
|
|
|
|
|
|
"basic"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Documented
|
|
|
|
|
|
|
|
basic.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Documented
|
|
|
|
|
|
|
|
full help.
|
|
|
|
|
|
|
|
]]
|
|
|
|
|
|
|
|
expect.eq(expected, h.get_entry_long_help('basic', 13))
|
|
|
|
|
|
|
|
|
|
|
|
-- long help for plugins/commands that have doc files should match the
|
|
|
|
-- long help for plugins/commands that have doc files should match the
|
|
|
|
-- contents of those files exactly
|
|
|
|
-- contents of those files exactly (test data is already wrapped)
|
|
|
|
expect.eq(files['hack/docs/docs/tools/hascommands.txt'],
|
|
|
|
expect.eq(files['hack/docs/docs/tools/hascommands.txt'],
|
|
|
|
h.get_entry_long_help('hascommands'))
|
|
|
|
h.get_entry_long_help('hascommands'))
|
|
|
|
expect.eq(files['hack/docs/docs/tools/hascommands.txt'],
|
|
|
|
expect.eq(files['hack/docs/docs/tools/hascommands.txt'],
|
|
|
|