mirror of
https://github.com/dhruvasagar/vim-table-mode.git
synced 2025-11-13 13:33:47 -05:00
Fixing tabular align for unicode characters
This commit is contained in:
18
t/align.vim
Normal file
18
t/align.vim
Normal file
@@ -0,0 +1,18 @@
|
||||
" vim: fdm=indent
|
||||
source t/config.vim
|
||||
|
||||
call vspec#hint({'scope': 'tablemode#align#scope()', 'sid': 'tablemode#align#sid()'})
|
||||
|
||||
describe 'Align'
|
||||
it 'should align table content correctly'
|
||||
let lines = ['| This | is a | table |', '| This | is also | a table |']
|
||||
let result = ['| This | is a | table |', '| This | is also | a table |']
|
||||
Expect tablemode#align#Align(lines) == result
|
||||
end
|
||||
|
||||
it 'should align table content with unicode characters correctly'
|
||||
let lines = ['| This | is 測試 | table |', '| This | is also | a table |']
|
||||
let result = ['| This | is 測試 | table |', '| This | is also | a table |']
|
||||
Expect tablemode#align#Align(lines) == result
|
||||
end
|
||||
end
|
||||
Reference in New Issue
Block a user