mirror of
https://github.com/davidhalter/jedi-vim.git
synced 2025-12-06 18:54:44 +08:00
tests: move/rename/cleanup vspec based tests (#860)
The main motivation is to being able to use normal/other pytest based tests. Therefore this moves everything from conftest into test_integration itself.
This commit is contained in:
31
test/vspec/documentation.vim
Normal file
31
test/vspec/documentation.vim
Normal file
@@ -0,0 +1,31 @@
|
||||
source plugin/jedi.vim
|
||||
|
||||
describe 'documentation docstrings'
|
||||
before
|
||||
set filetype=python
|
||||
end
|
||||
|
||||
after
|
||||
try | %bwipeout! | catch | endtry
|
||||
end
|
||||
|
||||
it 'simple'
|
||||
Expect maparg('K') == ':call jedi#show_documentation()<CR>'
|
||||
put = 'ImportError'
|
||||
normal GK
|
||||
Expect bufname('%') == "__doc__"
|
||||
Expect &filetype == 'rst'
|
||||
let content = join(getline(1,'$'), "\n")
|
||||
Expect stridx(content, "Import can't find module") > 0
|
||||
normal K
|
||||
Expect bufname('%') == ''
|
||||
end
|
||||
|
||||
it 'no documentation'
|
||||
put = 'x = 2'
|
||||
normal o<ESC>GK
|
||||
Expect bufname('%') == ''
|
||||
end
|
||||
end
|
||||
|
||||
" vim: et:ts=4:sw=4
|
||||
Reference in New Issue
Block a user