test: harden daemon lifecycle and e2e reliability across app/cli/server

This commit is contained in:
Mohamed Boudra
2026-02-25 10:21:46 +07:00
parent 094ce49d4f
commit a060ae1256
98 changed files with 5716 additions and 1771 deletions
+5 -6
View File
@@ -7,6 +7,7 @@ import {
waitForPermissionPrompt,
allowPermission,
denyPermission,
waitForAgentFinishUI,
} from './helpers/app';
import { createTempGitRepo } from './helpers/workspace';
@@ -31,7 +32,7 @@ test.describe('permission prompts', () => {
try {
await createAgentWithConfig(page, {
directory: repo.path,
model: 'haiku',
provider: 'claude',
mode: 'Always Ask',
prompt,
});
@@ -71,7 +72,7 @@ test.describe('permission prompts', () => {
try {
await createAgentWithConfig(page, {
directory: repo.path,
model: 'haiku',
provider: 'claude',
mode: 'Always Ask',
prompt,
});
@@ -79,10 +80,8 @@ test.describe('permission prompts', () => {
await waitForPermissionPrompt(page, 30000);
await denyPermission(page);
await expect(page.getByText(/denied by the user|permission\/authorization check/i)).toBeVisible({
timeout: 30_000,
});
await waitForAgentFinishUI(page, 30000);
await expect(page.getByTestId('permission-request-question')).toHaveCount(0);
expect(existsSync(filePath)).toBe(false);