You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

22 lines
918 B

local neotest = require('neotest')
vim.keymap.set('n', '<leader>tr', function () neotest.run.run() end)
vim.keymap.set('n', '<leader>tR', function () neotest.run.run_last() end)
vim.keymap.set('n', '<leader>tf', function () neotest.run.run(vim.fn.expand('%')) end)
vim.keymap.set('n', '<leader>tS', function () neotest.run.stop() end)
vim.keymap.set('n', '<leader>ta', function () neotest.run.attach() end)
vim.keymap.set('n', '<leader>to', function () neotest.output.open() end)
vim.keymap.set('n', '<leader>ts', function () neotest.summary.toggle() end)
neotest.setup({
adapters = {
require("neotest-phpunit")({
root_files = { "phpunit.xml", "composer.json" },
phpunit_cmd = { "docker-compose", "exec", "fpm", "./vendor/bin/phpunit" },
filter_dirs = { "vendor" },
mapped_docker_dir = "/var/www",
append_to_cwd = '/api'
}),
},
})