summaryrefslogtreecommitdiff
path: root/test/test_autocmd_commands.vader
diff options
context:
space:
mode:
authorw0rp <devw0rp@gmail.com>2017-10-30 22:19:57 +0000
committerw0rp <devw0rp@gmail.com>2017-10-30 22:19:57 +0000
commit50f7ad35529e0672e4161e3c74be5cb87196a2f1 (patch)
tree3feeaa166f4a52a5cb4962cb890622168ba50547 /test/test_autocmd_commands.vader
parent1575b3d7ddc5c2844d987f2abb0a5defe493972b (diff)
downloadale-50f7ad35529e0672e4161e3c74be5cb87196a2f1.zip
#857 - Add b:ale_fix_on_save for controlling fixing on save for specific buffers
Diffstat (limited to 'test/test_autocmd_commands.vader')
-rw-r--r--test/test_autocmd_commands.vader26
1 files changed, 2 insertions, 24 deletions
diff --git a/test/test_autocmd_commands.vader b/test/test_autocmd_commands.vader
index 6bc3f5cd..88504a9b 100644
--- a/test/test_autocmd_commands.vader
+++ b/test/test_autocmd_commands.vader
@@ -155,32 +155,10 @@ Execute (g:ale_lint_on_filetype_changed = 1 should bind the FileType event):
\ ],
\ CheckAutocmd('ALERunOnFiletypeChangeGroup')
-Execute (g:ale_lint_on_save = 0 should bind no events):
- let g:ale_lint_on_save = 0
- let g:ale_fix_on_save = 0
-
- AssertEqual [], CheckAutocmd('ALERunOnSaveGroup')
-
-Execute (g:ale_lint_on_save = 1 should bind no events):
- let g:ale_lint_on_save = 1
- let g:ale_fix_on_save = 0
-
- AssertEqual [
- \ 'BufWritePost * call ale#events#SaveEvent(str2nr(expand(''<abuf>'')))',
- \], CheckAutocmd('ALERunOnSaveGroup')
-
-Execute (g:ale_lint_on_save = 0 and g:ale_fix_on_save = 1 should bind events):
- let g:ale_lint_on_save = 0
- let g:ale_fix_on_save = 1
-
- AssertEqual [
- \ 'BufWritePost * call ale#events#SaveEvent(str2nr(expand(''<abuf>'')))',
- \], CheckAutocmd('ALERunOnSaveGroup')
-
-Execute (g:ale_fix_on_save = 1 should bind events even when ALE is disabled):
+Execute (The SaveEvent should always be bound):
let g:ale_enabled = 0
let g:ale_lint_on_save = 0
- let g:ale_fix_on_save = 1
+ let g:ale_fix_on_save = 0
AssertEqual [
\ 'BufWritePost * call ale#events#SaveEvent(str2nr(expand(''<abuf>'')))',