mirror of
https://github.com/vim-airline/vim-airline-themes.git
synced 2026-05-11 09:08:45 +08:00
test creation of sections
This commit is contained in:
+24
@@ -0,0 +1,24 @@
|
||||
describe 'parts'
|
||||
it 'overwrites existing values'
|
||||
call airline#parts#define('foo', { 'test': '123' })
|
||||
Expect airline#parts#get('foo').test == '123'
|
||||
call airline#parts#define('foo', { 'test': '321' })
|
||||
Expect airline#parts#get('foo').test == '321'
|
||||
end
|
||||
|
||||
it 'can define a function part'
|
||||
call airline#parts#define_function('func', 'bar')
|
||||
Expect airline#parts#get('func').function == 'bar'
|
||||
end
|
||||
|
||||
it 'can define a text part'
|
||||
call airline#parts#define_text('text', 'bar')
|
||||
Expect airline#parts#get('text').text == 'bar'
|
||||
end
|
||||
|
||||
it 'can define a raw part'
|
||||
call airline#parts#define_raw('raw', 'bar')
|
||||
Expect airline#parts#get('raw').raw == 'bar'
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user