Unverified Commit 07364140 authored by Jimmy Miller's avatar Jimmy Miller Committed by GitHub

Fix flaky lazy-dynamic-imports.test (#99057)

Test was flaking on grabbing redbox error message. In my testing
grabbing the cli output instead got rid of the flakes.
parent 9bb1ad7c
...@@ -254,11 +254,13 @@ export const invalid = ;` ...@@ -254,11 +254,13 @@ export const invalid = ;`
`) `)
).toBe(false) ).toBe(false)
const cliOutput = next.getCliOutputFromHere()
await browser.elementByCss('#load-parse-error').click() await browser.elementByCss('#load-parse-error').click()
await waitForRedbox(browser) await retry(async () => {
expect(await getRedboxSource(browser)).toContain( expect(cliOutput()).toContain(
'parse-error-proves-target-was-analyzed' 'parse-error-proves-target-was-analyzed'
) )
})
} finally { } finally {
await next.patchFile(targetPath, originalTarget) await next.patchFile(targetPath, originalTarget)
await next.patchFile(demoPath, originalDemo) await next.patchFile(demoPath, originalDemo)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment