refactor: consolidate agent wait methods and use in-memory MCP transport

This commit is contained in:
Mohamed Boudra
2026-01-30 14:50:01 +07:00
parent 0618dc6b0d
commit 25c7d5afa9
24 changed files with 191 additions and 469 deletions
+1 -1
View File
@@ -422,7 +422,7 @@ export const denyPermission = async (page: Page) => {
await denyButton.click();
};
export async function waitForAgentIdle(page: Page, timeout = 30000) {
export async function waitForAgentFinishUI(page: Page, timeout = 30000) {
const stopButton = page.getByRole('button', { name: /stop|cancel/i });
await expect(stopButton).not.toBeVisible({ timeout });
}
+2 -2
View File
@@ -6,7 +6,7 @@ import {
waitForPermissionPrompt,
allowPermission,
denyPermission,
waitForAgentIdle,
waitForAgentFinishUI,
getToolCallCount,
} from './helpers/app';
import { createTempGitRepo } from './helpers/workspace';
@@ -63,7 +63,7 @@ test.describe('permission prompts', () => {
await waitForPermissionPrompt(page, 30000);
await denyPermission(page);
await waitForAgentIdle(page);
await waitForAgentFinishUI(page);
expect(existsSync(filePath)).toBe(false);