test for window switching and active/inactive splits.
This commit is contained in:
parent
1b91c71fc9
commit
f48031cde8
@ -1,5 +1,6 @@
|
|||||||
call airline#init#bootstrap()
|
call airline#init#bootstrap()
|
||||||
call airline#init#sections()
|
call airline#init#sections()
|
||||||
|
source plugin/airline.vim
|
||||||
|
|
||||||
function! MyFuncref(...)
|
function! MyFuncref(...)
|
||||||
call a:1.add_raw('hello world')
|
call a:1.add_raw('hello world')
|
||||||
@ -56,5 +57,26 @@ describe 'airline'
|
|||||||
call airline#remove_statusline_func('MyIgnoreFuncref')
|
call airline#remove_statusline_func('MyIgnoreFuncref')
|
||||||
Expect len(g:airline_statusline_funcrefs) == c
|
Expect len(g:airline_statusline_funcrefs) == c
|
||||||
end
|
end
|
||||||
|
|
||||||
|
it 'should overwrite the statusline with active and inactive splits'
|
||||||
|
wincmd s
|
||||||
|
Expect getwinvar(1, '&statusline') !~ 'inactive'
|
||||||
|
Expect getwinvar(2, '&statusline') =~ 'inactive'
|
||||||
|
wincmd c
|
||||||
|
end
|
||||||
|
|
||||||
|
it 'should collapse the inactive split if the variable is set true'
|
||||||
|
let g:airline_inactive_collapse = 1
|
||||||
|
wincmd s
|
||||||
|
Expect getwinvar(2, '&statusline') !~ 'airline#parts#mode'
|
||||||
|
wincmd c
|
||||||
|
end
|
||||||
|
|
||||||
|
it 'should not collapse the inactive split if the variable is set false'
|
||||||
|
let g:airline_inactive_collapse = 0
|
||||||
|
wincmd s
|
||||||
|
Expect getwinvar(2, '&statusline') != 'airline#parts#mode'
|
||||||
|
wincmd c
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user