Add regression test for #16.

This commit is contained in:
Paolo Capriotti 2012-08-02 00:45:30 +01:00
parent 97f70ea98b
commit b8841a5abc

View File

@ -130,5 +130,15 @@ case_nested_commands = do
i = info (p1 <**> helper) idm
checkHelpText "nested" i ["c", "b"]
case_many_args :: Assertion
case_many_args = do
let p = arguments str idm
i = info p idm
nargs = 20000
result = run i (replicate nargs "foo")
case result of
Left _ -> assertFailure "unexpected parse error"
Right xs -> nargs @=? length xs
main :: IO ()
main = $(defaultMainGenerator)