playwright snapshot stability (#2053)

stability attempt
This commit is contained in:
Kurt Hutten
2024-04-10 14:55:29 +10:00
committed by GitHub
parent 959433e357
commit bcbd3f5bfd

View File

@ -364,13 +364,15 @@ test('extrude on each default plane should be stable', async ({
await u.removeCurrentCode()
// add makeCode('XZ')
await u.openAndClearDebugPanel()
await page.locator('.cm-content').fill(makeCode(plane))
await u.doAndWaitForImageDiff(
() => page.locator('.cm-content').fill(makeCode(plane)),
200
)
// wait for execution done
await u.expectCmdLog('[data-message-type="execution-done"]')
await u.clearAndCloseDebugPanel()
await page.getByText('Code').click()
await page.waitForTimeout(150)
await expect(page).toHaveScreenshot({
maxDiffPixels: 100,
})