mirror of
https://github.com/dense-analysis/ale.git
synced 2026-01-09 13:02:28 +08:00
Merge everything into the one global map.
This commit is contained in:
@@ -1,9 +1,7 @@
|
||||
Before:
|
||||
let g:ale_buffer_loclist_map = {}
|
||||
let g:ale_statusline_format = ['%sE', '%sW', 'OKIE']
|
||||
|
||||
After:
|
||||
let g:ale_buffer_loclist_map = {}
|
||||
let g:ale_buffer_info = {}
|
||||
|
||||
Execute (Count should be 0 when data is empty):
|
||||
@@ -20,19 +18,22 @@ Execute (The count should be correct after an update):
|
||||
AssertEqual [0, 0], ale#statusline#Count(44)
|
||||
|
||||
Execute (Count should be match the loclist):
|
||||
let g:ale_buffer_info = {bufnr('%'): {}}
|
||||
let g:ale_buffer_loclist_map = {bufnr('%'): [
|
||||
\ {
|
||||
\ 'lnum': 1,
|
||||
\ 'bufnr': 1,
|
||||
\ 'vcol': 0,
|
||||
\ 'linter_name': 'testlinter',
|
||||
\ 'nr': -1,
|
||||
\ 'type': 'E',
|
||||
\ 'col': 1,
|
||||
\ 'text': 'Test Error',
|
||||
\ },
|
||||
\]}
|
||||
let g:ale_buffer_info = {
|
||||
\ bufnr('%'): {
|
||||
\ 'loclist': [
|
||||
\ {
|
||||
\ 'lnum': 1,
|
||||
\ 'bufnr': 1,
|
||||
\ 'vcol': 0,
|
||||
\ 'linter_name': 'testlinter',
|
||||
\ 'nr': -1,
|
||||
\ 'type': 'E',
|
||||
\ 'col': 1,
|
||||
\ 'text': 'Test Error',
|
||||
\ },
|
||||
\ ],
|
||||
\ },
|
||||
\}
|
||||
AssertEqual [1, 0], ale#statusline#Count(bufnr('%'))
|
||||
|
||||
Execute (Output should be empty for non-existant buffer):
|
||||
|
||||
Reference in New Issue
Block a user