This commit is contained in:
Simon Knott 2025-06-11 15:10:17 +02:00
parent 77946c0f5d
commit ab696c2b10

View File

@ -138,10 +138,16 @@ test('navigating to download link emits download', async ({ startClient, server,
res.end('Hello world!');
});
expect(await client.callTool({
const navigateResponse = await client.callTool({
name: 'browser_navigate',
arguments: {
url: server.PREFIX + 'download',
},
})).toContainTextContent('### Downloads');
});
if (process.platform === 'win32') {
// windows is racy, downloads might arrive after the snapshot
await expect.poll(() => client.callTool({ name: 'browser_snapshot' })).toContainTextContent('### Downloads');
} else {
expect(navigateResponse).toContainTextContent('### Downloads');
}
});