Unverified Commit eed2086c authored by JJ Kasper's avatar JJ Kasper Committed by GitHub
parent 4911a27e
...@@ -4,7 +4,9 @@ import { ...@@ -4,7 +4,9 @@ import {
hasRedbox, hasRedbox,
getRedboxSource, getRedboxSource,
getRedboxDescription, getRedboxDescription,
check,
} from 'next-test-utils' } from 'next-test-utils'
import stripAnsi from 'strip-ansi'
createNextDescribe( createNextDescribe(
'fetch failures have good stack traces in edge runtime', 'fetch failures have good stack traces in edge runtime',
...@@ -33,7 +35,8 @@ createNextDescribe( ...@@ -33,7 +35,8 @@ createNextDescribe(
it('when returning `fetch` using an unknown domain, stack traces are preserved', async () => { it('when returning `fetch` using an unknown domain, stack traces are preserved', async () => {
await webdriver(next.appPort, '/api/unknown-domain-no-await') await webdriver(next.appPort, '/api/unknown-domain-no-await')
expect(next.cliOutput).toMatch( await check(
() => stripAnsi(next.cliOutput),
/at.+\/pages\/api\/unknown-domain-no-await.js/ /at.+\/pages\/api\/unknown-domain-no-await.js/
) )
}) })
......
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