Fix failing og api e2e test (#47500)

x-ref: https://github.com/vercel/next.js/actions/runs/4508438652/jobs/7937409460
This commit is contained in:
JJ Kasper 2023-03-24 08:59:45 -07:00 committed by GitHub
parent 68abad58ed
commit ba9b94d5fb
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -53,7 +53,9 @@ describe('og-api', () => {
)
).toBe(true)
})
} else {
}
if ((global as any).isNextDev) {
it('should throw error when returning a response object in pages/api in node runtime', async () => {
const res = await fetchViaHTTP(next.url, '/api/og-wrong-runtime')
expect(res.status).toBe(500)