use pythonvenv in neotest

This commit is contained in:
Oliver Hartmann 2023-02-15 11:08:19 +01:00
parent 5b4001d7e8
commit 99690477af

View File

@ -7,6 +7,7 @@ return {
'nvim-neotest/neotest-python' 'nvim-neotest/neotest-python'
}, },
config = function() config = function()
local pythonVenv = require('utils.python_venv')
require('neotest').setup({ require('neotest').setup({
adapters = { adapters = {
require('neotest-python')({ require('neotest-python')({
@ -15,6 +16,7 @@ return {
}, },
args = { '--log-level', 'DEBUG' }, args = { '--log-level', 'DEBUG' },
runner = 'pytest', runner = 'pytest',
python = pythonVenv.getPythonEnv
}) })
} }
}) })