From df90725c858103f1c63eb1c96f3e4e4727c32a7d Mon Sep 17 00:00:00 2001 From: w0rp Date: Sat, 11 May 2019 17:19:45 +0100 Subject: Support b:ale_completion_enabled for disabling it for some buffers --- test/completion/test_completion_events.vader | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'test/completion') diff --git a/test/completion/test_completion_events.vader b/test/completion/test_completion_events.vader index f79773cc..cdd3fea4 100644 --- a/test/completion/test_completion_events.vader +++ b/test/completion/test_completion_events.vader @@ -5,6 +5,7 @@ Before: Save &l:omnifunc Save &l:completeopt + unlet! b:ale_completion_enabled let g:ale_completion_enabled = 1 let g:get_completions_called = 0 let g:feedkeys_calls = [] @@ -49,6 +50,7 @@ Before: After: Restore + unlet! b:ale_completion_enabled unlet! g:output unlet! g:fake_mode unlet! g:get_completions_called @@ -78,6 +80,14 @@ After: Execute(ale#completion#GetCompletions should be called when the cursor position stays the same): call CheckCompletionCalled(1) +Execute(ale#completion#GetCompletions should not be called if the global setting is disabled): + let g:ale_completion_enabled = 0 + call CheckCompletionCalled(0) + +Execute(ale#completion#GetCompletions should not be called if the buffer setting is disabled): + let b:ale_completion_enabled = 0 + call CheckCompletionCalled(0) + Given typescript(): let abc = y. let foo = ab -- cgit v1.2.3