feat: Replace python tests with native E2E test suite and fix capabilities schema

- Added native E2E test suite in stub to validate server<->stub<->nvim IPC
- Added win-nvim integration tests
- Fixed empty capabilities schema in initialize response in server and win-nvim
- Refactored server to accept dynamic MCP_PORT for test isolation
- Made server exit gracefully on port 3000 collision
This commit is contained in:
Riz Ashraf committed 2026-09-13 18:03:27 +01:00
1 parent f2582b58be
commit d71b1e6e35
11 files changed
+327 -79

No files matched your search

+12 -1
View File
@@ -60,6 +60,10 @@ local function execute_agent(prompt)
M.show_progress("Starting Antigravity...")
-- termopen requires an empty and unmodified buffer
vim.api.nvim_buf_set_lines(progress_buf, 0, -1, false, {})
vim.bo[progress_buf].modified = false
-- termopen will attach to the current buffer (which show_progress just focused)
job_id = vim.fn.termopen(cmd, {
on_exit = function(_, code)
@@ -70,9 +74,16 @@ local function execute_agent(prompt)
end
function M.ask_agent()
local file = vim.api.nvim_buf_get_name(0)
vim.ui.input({ prompt = 'Ask Agent: ' }, function(input)
if not input or input == '' then return end
execute_agent(input)
local final_input = input
if file and file ~= "" then
final_input = input .. string.format(" [Context file: %s]", file)
end
execute_agent(final_input)
end)
end