From 99361b2ca92bb6b70056ee558088e386745435a6 Mon Sep 17 00:00:00 2001 From: Rob Looby Date: Sun, 14 Apr 2019 11:18:50 -0500 Subject: Add floskell for Haskell formatting --- test/fixers/test_floskell_fixer_callback.vader | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 test/fixers/test_floskell_fixer_callback.vader (limited to 'test') diff --git a/test/fixers/test_floskell_fixer_callback.vader b/test/fixers/test_floskell_fixer_callback.vader new file mode 100644 index 00000000..66fe9200 --- /dev/null +++ b/test/fixers/test_floskell_fixer_callback.vader @@ -0,0 +1,23 @@ +Before: + Save g:ale_haskell_floskell_executable + + " Use an invalid global executable, so we don't match it. + let g:ale_haskell_floskell_executable = 'xxxinvalid' + + call ale#test#SetDirectory('/testplugin/test/fixers') + +After: + Restore + + call ale#test#RestoreDirectory() + +Execute(The floskell callback should return the correct default values): + call ale#test#SetFilename('../haskell_files/testfile.hs') + + AssertEqual + \ { + \ 'read_temporary_file': 1, + \ 'command': ale#Escape('xxxinvalid') + \ . ' %t', + \ }, + \ ale#fixers#floskell#Fix(bufnr('')) -- cgit v1.2.3