()
| 8 | const PAGES = ['HOME','PLAYGROUND','EXPLAIN','ROUTING','MODELS','ACTIVITY','CONNECTIONS','BUDGET','FEEDBACK']; |
| 9 | |
| 10 | async function run() { |
| 11 | const browser = await chromium.launch({ headless: true }); |
| 12 | const page = await (await browser.newContext({ viewport: { width: 1440, height: 900 } })).newPage(); |
| 13 | await page.goto(BASE, { waitUntil: 'networkidle', timeout: 30000 }); |
| 14 | await page.waitForTimeout(2000); |
| 15 | |
| 16 | for (const name of PAGES) { |
| 17 | await page.click(`button:has-text("${name}")`, { timeout: 5000 }); |
| 18 | await page.waitForTimeout(1500); |
| 19 | // For playground, type a complex prompt so we see results |
| 20 | if (name === 'PLAYGROUND') { |
| 21 | await page.locator('textarea').fill('Implement a B-tree with concurrent access, crash recovery, and MVCC support'); |
| 22 | await page.waitForTimeout(10000); // wait for embedding model + prediction |
| 23 | } |
| 24 | await page.screenshot({ path: `${DIR}/${name.toLowerCase()}.png`, fullPage: true }); |
| 25 | console.log(`✓ ${name}`); |
| 26 | } |
| 27 | await browser.close(); |
| 28 | } |
| 29 | run().catch(e => { console.error(e); process.exit(1); }); |
no test coverage detected