1
0
mirror of https://github.com/SpaceVim/SpaceVim.git synced 2025-01-24 06:20:05 +08:00
SpaceVim/bundle/neomake/tests/ft_idris.vader
2020-06-13 14:06:35 +08:00

31 lines
980 B
Plaintext
Vendored

Include: include/setup.vader
Execute (idris: makers):
AssertEqual neomake#GetMakers('idris'), ['idris']
Execute (idris: errorformat):
" Test errorformat itself.
let idris_output =
\"t.idr:6:1-4:When checking left hand side of xor:\n
\When checking an application of Main.xor:\n
\ Type mismatch between\n
\ Integer (Type of 5)\n
\ and\n
\ Bool (Expected type)"
Save &errorformat
let &errorformat = neomake#makers#ft#idris#idris().errorformat
lgetexpr idris_output
AssertEqual len(getloclist(0)), 1
AssertEqual getloclist(0)[0].text, "4:When checking left hand side of xor:\n
\Type mismatch between\n
\Integer (Type of 5)\n
\and\n
\Bool (Expected type)"
let entry = getloclist(0)[0]
call call(neomake#makers#ft#idris#idris().postprocess, [entry])
AssertEqual entry.text, 'Type mismatch between Integer (Type of 5) and Bool (Expected type)'
AssertEqual entry.length, 3
bwipe t.idr