#734 - Use the buffer number from the events for entering buffers and saving buffers for checking buffers
This commit is contained in:
@@ -116,9 +116,9 @@ Execute (g:ale_lint_on_enter = 1 should bind the required events):
|
||||
let g:ale_lint_on_enter = 1
|
||||
|
||||
AssertEqual [
|
||||
\ 'BufEnter * call ale#events#EnterEvent()',
|
||||
\ 'BufReadPost * call ale#Queue(300, ''lint_file'')',
|
||||
\ 'BufWinEnter * call ale#Queue(300, ''lint_file'')',
|
||||
\ 'BufEnter * call ale#events#EnterEvent(str2nr(expand(''<abuf>'')))',
|
||||
\ 'BufReadPost * call ale#Queue(0, ''lint_file'', str2nr(expand(''<abuf>'')))',
|
||||
\ 'BufWinEnter * call ale#Queue(0, ''lint_file'', str2nr(expand(''<abuf>'')))',
|
||||
\ 'FileChangedShellPost * call ale#events#FileChangedEvent(str2nr(expand(''<abuf>'')))',
|
||||
\], CheckAutocmd('ALERunOnEnterGroup')
|
||||
|
||||
@@ -151,7 +151,7 @@ Execute (g:ale_lint_on_save = 1 should bind no events):
|
||||
let g:ale_fix_on_save = 0
|
||||
|
||||
AssertEqual [
|
||||
\ 'BufWritePost * call ale#events#SaveEvent()',
|
||||
\ '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):
|
||||
@@ -159,7 +159,7 @@ Execute (g:ale_lint_on_save = 0 and g:ale_fix_on_save = 1 should bind events):
|
||||
let g:ale_fix_on_save = 1
|
||||
|
||||
AssertEqual [
|
||||
\ 'BufWritePost * call ale#events#SaveEvent()',
|
||||
\ '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):
|
||||
@@ -168,7 +168,7 @@ Execute (g:ale_fix_on_save = 1 should bind events even when ALE is disabled):
|
||||
let g:ale_fix_on_save = 1
|
||||
|
||||
AssertEqual [
|
||||
\ 'BufWritePost * call ale#events#SaveEvent()',
|
||||
\ 'BufWritePost * call ale#events#SaveEvent(str2nr(expand(''<abuf>'')))',
|
||||
\], CheckAutocmd('ALERunOnSaveGroup')
|
||||
|
||||
Execute (g:ale_echo_cursor = 0 should bind no events):
|
||||
|
||||
Reference in New Issue
Block a user