haskell - How can I use multi-line input with QuickCheck in doctest? -


from doctest's readme, 1 can use doctest quickcheck, this:

-- | -- prop> sort xs == (sort . sort) (xs :: [int]) 

i describe property using multiple lines, like

-- | -- prop> sort xs == --            (sort . sort) (xs :: [int]) 

doctest supports multi-line input (again readme)

-- | -- >>> :{ --  let --    x = 1 --    y = 2 --  in x + y + multiline -- :} -- 6 

and tried several similar syntaxes came with, such as

-- | -- prop> :{ sort xs == --           (sort . sort) (xs :: [int]) -- }: 

without success. (in example above, error message parse error on input '{'.)

how can use multi-line input quickcheck in doctest?


Comments

Popular posts from this blog

c# - Validate object ID from GET to POST -

node.js - Custom Model Validator SailsJS -

php - Find a regex to take part of Email -