2020-06-04 23:29:47 +02:00
|
|
|
# Non regression tests for issues, see changelog
|
|
|
|
# In reverse chronological order
|
|
|
|
#
|
|
|
|
# Thanks to all contributors with issues and pull request on github
|
|
|
|
#
|
|
|
|
|
|
|
|
|
|
|
|
Include: vader_includes/vader_setup.vader
|
|
|
|
|
|
|
|
|
2020-07-24 06:16:09 +02:00
|
|
|
Execute (Log):
|
|
|
|
Log '#949 <Enter> create link bug with Chinese characters'
|
|
|
|
|
|
|
|
Given vimwiki (Madarin with vimwiki Yeeepy):
|
|
|
|
你
|
|
|
|
你好
|
|
|
|
你们好
|
|
|
|
你们好啊
|
|
|
|
你们好啊啊
|
|
|
|
你们好啊aaaaa
|
|
|
|
aaaaa你们好啊
|
|
|
|
|
|
|
|
Do (Enter in all):
|
|
|
|
\<Cr>j \<Cr>j \<Cr>j \<Cr>j \<Cr>j \<Cr>j \<Cr>j
|
|
|
|
|
|
|
|
Expect (all WORDS are links):
|
|
|
|
[你](你)
|
|
|
|
[你好](你好)
|
|
|
|
[你们好](你们好)
|
|
|
|
[你们好啊](你们好啊)
|
|
|
|
[你们好啊啊](你们好啊啊)
|
|
|
|
[你们好啊aaaaa](你们好啊aaaaa)
|
|
|
|
[aaaaa你们好啊](aaaaa你们好啊)
|
|
|
|
|
|
|
|
|
|
|
|
Execute (Log):
|
|
|
|
Log '#735 Fix off-by-one error in get_next_line and get_prev_line'
|
|
|
|
|
2020-06-04 23:29:47 +02:00
|
|
|
Given vimwiki (P#735 -> I#407):
|
|
|
|
1. item1
|
|
|
|
2. item2
|
|
|
|
```
|
|
|
|
echo "hello world"
|
|
|
|
```
|
|
|
|
3. item3
|
|
|
|
|
|
|
|
Do (o):
|
|
|
|
o
|
|
|
|
|
|
|
|
Expect (Renumber all):
|
|
|
|
1. item1
|
|
|
|
2.
|
|
|
|
3. item2
|
|
|
|
```
|
|
|
|
echo "hello world"
|
|
|
|
```
|
|
|
|
4. item3
|
|
|
|
|
|
|
|
|
2020-07-24 06:16:09 +02:00
|
|
|
Execute (Log):
|
|
|
|
Log '#899 conceallevel is setted globally when editing a wiki file (PR #900)'
|
|
|
|
|
2020-06-04 23:29:47 +02:00
|
|
|
Given vimwiki (Void):
|
|
|
|
|
|
|
|
Execute (conceal):
|
|
|
|
set conceallevel=1
|
|
|
|
let g:vimwiki_global_vars['conceallevel']=2
|
2020-07-24 06:16:09 +02:00
|
|
|
|
|
|
|
Log ' ConcealLevel is set to vimwiki for a .md'
|
2020-06-04 23:29:47 +02:00
|
|
|
call SetSyntax('markdown')
|
|
|
|
file main.md
|
|
|
|
edit
|
|
|
|
AssertEqual &ft, 'vimwiki'
|
|
|
|
AssertEqual @%, 'main.md'
|
|
|
|
if exists('+conceallevel')
|
|
|
|
AssertEqual &conceallevel, 2
|
|
|
|
endif
|
2020-07-24 06:16:09 +02:00
|
|
|
|
|
|
|
Log ' ConcealLevel is set to vim for a no_ext'
|
|
|
|
edit no_ext
|
|
|
|
AssertEqual &ft, ''
|
|
|
|
if exists('+conceallevel')
|
|
|
|
AssertEqual &conceallevel, 1
|
|
|
|
endif
|
|
|
|
|
|
|
|
Log ' Again ConcealLevel is set to vimwiki for a .md (just for fun)'
|
|
|
|
let g:vimwiki_global_vars['conceallevel']=0
|
|
|
|
edit new.md
|
|
|
|
AssertEqual &ft, 'vimwiki'
|
|
|
|
AssertEqual @%, 'new.md'
|
|
|
|
if exists('+conceallevel')
|
|
|
|
AssertEqual &conceallevel, 0
|
|
|
|
endif
|
|
|
|
|
|
|
|
|
|
|
|
Execute (Log):
|
|
|
|
Log 'PR #528: Add option |g:vimwiki_create_link| to prevent link creation'
|
|
|
|
|
2020-06-04 23:29:47 +02:00
|
|
|
Given vimwiki (Link):
|
|
|
|
Link
|
|
|
|
|
|
|
|
Do (Enter):
|
|
|
|
\<CR>
|
|
|
|
|
|
|
|
# TODO should be Link.md, revise the test
|
|
|
|
Expect (Link):
|
|
|
|
[Link](Link)
|
|
|
|
|
|
|
|
Do (<CR><CR>):
|
|
|
|
\<CR>\<CR>
|
|
|
|
:AssertEqual expand('%:t'), 'Link.md'\<CR>
|
|
|
|
|
|
|
|
Given vimwiki (Link):
|
|
|
|
Link
|
|
|
|
|
|
|
|
Do (No link: <CR><CR>):
|
|
|
|
:call vimwiki#vars#set_global('markdown_create_link', 0)
|
|
|
|
\<CR>\<CR>
|
|
|
|
:AssertEqual expand('%:t'), 'main.md'\<CR>
|
|
|
|
|
|
|
|
|
|
|
|
Include: vader_includes/vader_teardown.vader
|