summaryrefslogtreecommitdiff
path: root/test/fix
diff options
context:
space:
mode:
authorw0rp <devw0rp@gmail.com>2018-06-21 01:21:11 +0100
committerw0rp <devw0rp@gmail.com>2018-06-21 01:21:11 +0100
commit69eb2fe86adaba5276e20d01c690d7ddaa8a5f1a (patch)
tree6a76713023b91ee0feb2becfe85dcf5cd4246088 /test/fix
parent34755eecdd767880af58a91c1b275fdd5ea843a8 (diff)
downloadale-69eb2fe86adaba5276e20d01c690d7ddaa8a5f1a.zip
Close #1417 - Support wildcard filetypes for fixers
Diffstat (limited to 'test/fix')
-rw-r--r--test/fix/test_ale_fix.vader19
1 files changed, 19 insertions, 0 deletions
diff --git a/test/fix/test_ale_fix.vader b/test/fix/test_ale_fix.vader
index 3bd23672..417394c3 100644
--- a/test/fix/test_ale_fix.vader
+++ b/test/fix/test_ale_fix.vader
@@ -257,6 +257,25 @@ Expect(Only the second function should be applied):
$b
$c
+Execute(The * fixers shouldn't be used if an empty list is set for fixers):
+ let g:ale_fixers.testft = []
+ let g:ale_fixers['*'] = ['AddDollars']
+ ALEFix
+
+Expect(Nothing should be changed):
+ a
+ b
+ c
+
+Execute(* fixers should be used if no filetype is matched):
+ let g:ale_fixers = {'*': ['AddDollars']}
+ ALEFix
+
+Expect(The file should be changed):
+ $a
+ $b
+ $c
+
Execute(ALEFix should allow commands to be run):
if has('win32')
" Just skip this test on Windows, we can't run it.