aboutsummaryrefslogtreecommitdiff
path: root/test/functional/provider/python_spec.lua
diff options
context:
space:
mode:
Diffstat (limited to 'test/functional/provider/python_spec.lua')
-rw-r--r--test/functional/provider/python_spec.lua15
1 files changed, 9 insertions, 6 deletions
diff --git a/test/functional/provider/python_spec.lua b/test/functional/provider/python_spec.lua
index 94dfa90ea8..869cfd1721 100644
--- a/test/functional/provider/python_spec.lua
+++ b/test/functional/provider/python_spec.lua
@@ -8,19 +8,22 @@ local funcs = helpers.funcs
local meths = helpers.meths
local insert = helpers.insert
local expect = helpers.expect
+local expect_err = helpers.expect_err
local command = helpers.command
local exc_exec = helpers.exc_exec
local write_file = helpers.write_file
local curbufmeths = helpers.curbufmeths
+local missing_provider = helpers.missing_provider
do
clear()
- command('let [g:interp, g:errors] = provider#pythonx#Detect(2)')
- local errors = meths.get_var('errors')
- if errors ~= '' then
- pending(
- 'Python 2 (or the Python 2 neovim module) is broken or missing:\n' .. errors,
- function() end)
+ if missing_provider('python') then
+ it(':python reports E319 if provider is missing', function()
+ local expected = [[Vim%(py.*%):E319: No "python" provider found.*]]
+ expect_err(expected, command, 'py print("foo")')
+ expect_err(expected, command, 'pyfile foo')
+ end)
+ pending('Python 2 (or the pynvim module) is broken/missing', function() end)
return
end
end