test(web): verify multi-keyframe animation editing
Some checks failed
M6 deployable RC / quick (push) Has been cancelled
M6 deployable RC / chromium (push) Has been cancelled
M6 deployable RC / release (push) Has been cancelled

Co-Authored-By: Claude Code <noreply@anthropic.com>
This commit is contained in:
mes123456
2026-11-14 10:04:56 +08:00
parent 258dcf0098
commit 9d56445f4a
3 changed files with 23 additions and 13 deletions

View File

@@ -72,19 +72,27 @@ try {
await page.keyboard.press("g");
await page.waitForTimeout(1800);
log("key1", JSON.stringify(await autoKeyState()));
await page.getByRole("button", { name: "下一帧", exact: true }).click();
await page.waitForTimeout(1200);
for (let index = 0; index < 9; index++) {
await page.getByRole("button", { name: "下一帧", exact: true }).click();
await page.waitForTimeout(150);
}
await page.waitForTimeout(600);
log("frame", await page.evaluate(() => document.querySelector('input[aria-label="当前帧"]')?.value ?? null));
await page.evaluate(() => document.activeElement instanceof HTMLElement && document.activeElement.blur());
await page.keyboard.press("g");
await page.waitForTimeout(1800);
log("key2", JSON.stringify(await autoKeyState()));
const valueInput = page.locator('input[aria-label="Keyframe value"]').first();
if (await valueInput.count()) {
await valueInput.fill("0.5");
await valueInput.press("Enter");
await page.waitForTimeout(1500);
log("edited", JSON.stringify(await autoKeyState()));
} else {
log("no keyframe editor");
}
const dots = await page.locator('.key-dot').count();
log("dots", dots, JSON.stringify(await page.locator('.key-dot').evaluateAll((nodes) => nodes.map((node) => node.getAttribute('aria-label')))));
if (dots) {
await page.locator('.key-dot').first().click();
await page.waitForTimeout(800);
const frame = await page.evaluate(() => document.querySelector('input[aria-label="当前帧"]')?.value ?? null);
log("after dot", frame);
}
} catch (error) {
log("probe error", error instanceof Error ? error.message : String(error));
log("state", JSON.stringify(await autoKeyState().catch(() => null)));