Doubao-powered voice input for Linux, Wayland and Omarchy
fix(e2e): show selected final step in CI preview (#26)
Leyang080b1d566346
diff --git a/tests/e2e/capture-report-preview.mjs b/tests/e2e/capture-report-preview.mjsindex 7524f1d..f7808ce 100644--- a/tests/e2e/capture-report-preview.mjs+++ b/tests/e2e/capture-report-preview.mjs@@ -39,10 +39,7 @@ const report = await findLatestTestReport(reportDirectory);const runnerDump = report.run;if (!runnerDump) throw new Error('Midscene Test runner dump was not found');const previewUrl = new URL(pathToFileURL(report.file));-previewUrl.hash = new URLSearchParams({- 'runner-step': 'last',- 'runner-trace': 'page',-}).toString();+previewUrl.hash = new URLSearchParams({ 'runner-step': 'last' }).toString();await mkdir(path.dirname(outputFile), { recursive: true });const browser = await puppeteer.launch({@@ -57,7 +54,10 @@ try {await page.goto(previewUrl.href, {waitUntil: 'networkidle0',});- await page.waitForFunction(() => document.body.innerText.includes('AI TRACE'));+ await page.waitForSelector('[aria-label="Execution steps"]');+ await page.waitForFunction(() =>+ /STEPS\s*\xb7\s*STEP\s+\d+/i.test(document.body.innerText),+ );await page.evaluate(() => window.scrollTo(0, 0));await page.waitForFunction(() =>/Passed|Failed|Error/.test(document.body.innerText),