|
|
@ -1,16 +1,22 @@ |
|
|
|
require("neotest").setup({ |
|
|
|
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" } |
|
|
|
phpunit_cmd = { "docker-compose", "exec", "fpm", "./vendor/bin/phpunit" }, |
|
|
|
filter_dirs = { "vendor" }, |
|
|
|
mapped_docker_dir = "/var/www", |
|
|
|
append_to_cwd = '/api' |
|
|
|
}), |
|
|
|
}, |
|
|
|
}) |
|
|
|
|
|
|
|
require("neotest-phpunit")({ |
|
|
|
root_files = { "phpunit.xml", "composer.json" }, |
|
|
|
phpunit_cmd = { "docker-compose", "exec", "fpm", "./vendor/bin/phpunit" }, |
|
|
|
-- phpunit_cmd = { "vendor/bin/phpunit" }, |
|
|
|
filter_dirs = { "vendor" } |
|
|
|
}) |