diff --git a/powerline/bindings/vim/plugin/powerline.vim b/powerline/bindings/vim/plugin/powerline.vim index 78e9ff53..ad2c60fc 100644 --- a/powerline/bindings/vim/plugin/powerline.vim +++ b/powerline/bindings/vim/plugin/powerline.vim @@ -40,5 +40,6 @@ finally endif endtry +execute s:pycmd 'import vim' execute s:pycmd 'powerline_setup(pyeval=vim.eval("s:pyeval"), pycmd=vim.eval("s:pycmd"))' execute s:pycmd 'del powerline_setup' diff --git a/tests/test.sh b/tests/test.sh index c65e6668..9bbe0b2e 100755 --- a/tests/test.sh +++ b/tests/test.sh @@ -10,4 +10,7 @@ done if ! ${PYTHON} scripts/powerline-lint -p powerline/config_files ; then FAILED=1 fi +if ! vim -S tests/test_plugin_file.vim ; then + FAILED=1 +fi exit $FAILED diff --git a/tests/test_plugin_file.vim b/tests/test_plugin_file.vim new file mode 100755 index 00000000..6c9c3a6f --- /dev/null +++ b/tests/test_plugin_file.vim @@ -0,0 +1,16 @@ +#!/usr/bin/vim -S +set nocompatible +try + source powerline/bindings/vim/plugin/powerline.vim +catch + cquit +endtry +set ls=2 +redrawstatus! +redir =>mes + messages +redir END +if len(split(mes, "\n"))>1 + cquit +endif +quit!