Open joshyt100 opened 10 months ago
Are you using the latest master commit? There was a bug fixed in #62 that could be the issue. If that is not the problem, please provide the information requested in the neotest bug report template
This is how I have everything setup. I'm also using lunarvim.
lvim.plugins = {
"mfussenegger/nvim-dap-python", "nvim-neotest/neotest", "nvim-neotest/neotest-python" }
lvim.builtin.dap.active = true local mason_path = vim.fn.glob(vim.fn.stdpath "data" .. "/mason/") pcall(function() require("dap-python").setup(mason_path .. "packages/debugpy/venv/bin/python") end)
require("neotest").setup({ adapters = { require("neotest-python")({ dap = { justMyCode = false, console = "integratedTerminal", }, args = { "--log-level", "DEBUG", "--quiet" }, runner = "unittest", }) } })
I assume you are using venv
. If in your code base, can you suspend lunarvim (ctrl+z), open the python interpreter and try to import unittest
. Does this work?
Are there any logs you can provide? Which python version are you using?
This is my neotest setup: require("neotest").setup({ adapters = { require("neotest-python")({ -- Extra arguments for nvim-dap configuration -- See https://github.com/microsoft/debugpy/wiki/Debug-configuration-settings for values dap = { justMyCode = false, console = "integratedTerminal", }, args = { "--log-level", "DEBUG", "--quiet" }, runner = "unittest", }) } I am able to get it to work with pytest, but I can't figure out how to use it with unittest. What am I doing wrong?