-
Notifications
You must be signed in to change notification settings - Fork 26.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Revert "Temporarily disable app dir export integration test" (#49311)
- Reverts #48291 - Fixes #49059 - TODO: move these tests to `./tests/e2e/*` to avoid flakes (that will be a follow up PR) fix NEXT-1092
- Loading branch information
Showing
9 changed files
with
95 additions
and
86 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
32 changes: 15 additions & 17 deletions
32
test/integration/app-dir-export/test/dynamicapiroute-dev.test.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,19 +1,17 @@ | ||
import { runTests } from './utils' | ||
|
||
describe.skip('dynamic api route dev', () => { | ||
it.each([ | ||
{ dynamicApiRoute: 'undefined' }, | ||
{ dynamicApiRoute: "'error'" }, | ||
{ dynamicApiRoute: "'force-static'" }, | ||
{ | ||
dynamicApiRoute: "'force-dynamic'", | ||
expectedErrMsg: | ||
'export const dynamic = "force-dynamic" on page "/api/json" cannot be used with "output: export".', | ||
}, | ||
])( | ||
'should work in dev with dynamicApiRoute $dynamicApiRoute', | ||
async ({ dynamicApiRoute, expectedErrMsg }) => { | ||
await runTests({ isDev: true, dynamicApiRoute, expectedErrMsg }) | ||
} | ||
) | ||
}) | ||
it.each([ | ||
{ dynamicApiRoute: 'undefined' }, | ||
{ dynamicApiRoute: "'error'" }, | ||
{ dynamicApiRoute: "'force-static'" }, | ||
{ | ||
dynamicApiRoute: "'force-dynamic'", | ||
expectedErrMsg: | ||
'export const dynamic = "force-dynamic" on page "/api/json" cannot be used with "output: export".', | ||
}, | ||
])( | ||
'should work in dev with dynamicApiRoute $dynamicApiRoute', | ||
async ({ dynamicApiRoute, expectedErrMsg }) => { | ||
await runTests({ isDev: true, dynamicApiRoute, expectedErrMsg }) | ||
} | ||
) |
32 changes: 15 additions & 17 deletions
32
test/integration/app-dir-export/test/dynamicapiroute-prod.test.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,19 +1,17 @@ | ||
import { runTests } from './utils' | ||
|
||
describe.skip('dynamic api route prod', () => { | ||
it.each([ | ||
{ dynamicApiRoute: 'undefined' }, | ||
{ dynamicApiRoute: "'error'" }, | ||
{ dynamicApiRoute: "'force-static'" }, | ||
{ | ||
dynamicApiRoute: "'force-dynamic'", | ||
expectedErrMsg: | ||
'export const dynamic = "force-dynamic" on page "/api/json" cannot be used with "output: export".', | ||
}, | ||
])( | ||
'should work in prod with dynamicApiRoute $dynamicApiRoute', | ||
async ({ dynamicApiRoute, expectedErrMsg }) => { | ||
await runTests({ isDev: false, dynamicApiRoute, expectedErrMsg }) | ||
} | ||
) | ||
}) | ||
it.each([ | ||
{ dynamicApiRoute: 'undefined' }, | ||
{ dynamicApiRoute: "'error'" }, | ||
{ dynamicApiRoute: "'force-static'" }, | ||
{ | ||
dynamicApiRoute: "'force-dynamic'", | ||
expectedErrMsg: | ||
'export const dynamic = "force-dynamic" on page "/api/json" cannot be used with "output: export".', | ||
}, | ||
])( | ||
'should work in prod with dynamicApiRoute $dynamicApiRoute', | ||
async ({ dynamicApiRoute, expectedErrMsg }) => { | ||
await runTests({ isDev: false, dynamicApiRoute, expectedErrMsg }) | ||
} | ||
) |
32 changes: 15 additions & 17 deletions
32
test/integration/app-dir-export/test/dynamicpage-dev.test.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,19 +1,17 @@ | ||
import { runTests } from './utils' | ||
|
||
describe.skip('dynamic page dev', () => { | ||
it.each([ | ||
{ dynamicPage: 'undefined' }, | ||
{ dynamicPage: "'error'" }, | ||
{ dynamicPage: "'force-static'" }, | ||
{ | ||
dynamicPage: "'force-dynamic'", | ||
expectedErrMsg: | ||
'Page with `dynamic = "force-dynamic"` couldn\'t be rendered statically because it used `output: export`.', | ||
}, | ||
])( | ||
'should work in dev with dynamicPage $dynamicPage', | ||
async ({ dynamicPage, expectedErrMsg }) => { | ||
await runTests({ isDev: true, dynamicPage, expectedErrMsg }) | ||
} | ||
) | ||
}) | ||
it.each([ | ||
{ dynamicPage: 'undefined' }, | ||
{ dynamicPage: "'error'" }, | ||
{ dynamicPage: "'force-static'" }, | ||
{ | ||
dynamicPage: "'force-dynamic'", | ||
expectedErrMsg: | ||
'Page with `dynamic = "force-dynamic"` couldn\'t be rendered statically because it used `output: export`.', | ||
}, | ||
])( | ||
'should work in dev with dynamicPage $dynamicPage', | ||
async ({ dynamicPage, expectedErrMsg }) => { | ||
await runTests({ isDev: true, dynamicPage, expectedErrMsg }) | ||
} | ||
) |
32 changes: 15 additions & 17 deletions
32
test/integration/app-dir-export/test/dynamicpage-prod.test.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,19 +1,17 @@ | ||
import { runTests } from './utils' | ||
|
||
describe.skip('dynamic page dev', () => { | ||
it.each([ | ||
{ dynamicPage: 'undefined' }, | ||
{ dynadynamicPagemic: "'error'" }, | ||
{ dynamicPage: "'force-static'" }, | ||
{ | ||
dynamicPage: "'force-dynamic'", | ||
expectedErrMsg: | ||
'Page with `dynamic = "force-dynamic"` couldn\'t be rendered statically because it used `output: export`.', | ||
}, | ||
])( | ||
'should work in prod with dynamicPage $dynamicPage', | ||
async ({ dynamicPage, expectedErrMsg }) => { | ||
await runTests({ isDev: false, dynamicPage, expectedErrMsg }) | ||
} | ||
) | ||
}) | ||
it.each([ | ||
{ dynamicPage: 'undefined' }, | ||
{ dynadynamicPagemic: "'error'" }, | ||
{ dynamicPage: "'force-static'" }, | ||
{ | ||
dynamicPage: "'force-dynamic'", | ||
expectedErrMsg: | ||
'Page with `dynamic = "force-dynamic"` couldn\'t be rendered statically because it used `output: export`.', | ||
}, | ||
])( | ||
'should work in prod with dynamicPage $dynamicPage', | ||
async ({ dynamicPage, expectedErrMsg }) => { | ||
await runTests({ isDev: false, dynamicPage, expectedErrMsg }) | ||
} | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
14 changes: 6 additions & 8 deletions
14
test/integration/app-dir-export/test/trailing-slash-dev.test.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,8 @@ | ||
import { runTests } from './utils' | ||
|
||
describe.skip('trailing slash dev', () => { | ||
it.each([{ trailingSlash: false }, { trailingSlash: true }])( | ||
"should work in dev with trailingSlash '$trailingSlash'", | ||
async ({ trailingSlash }) => { | ||
await runTests({ isDev: true, trailingSlash }) | ||
} | ||
) | ||
}) | ||
it.each([{ trailingSlash: false }, { trailingSlash: true }])( | ||
"should work in dev with trailingSlash '$trailingSlash'", | ||
async ({ trailingSlash }) => { | ||
await runTests({ isDev: true, trailingSlash }) | ||
} | ||
) |
14 changes: 6 additions & 8 deletions
14
test/integration/app-dir-export/test/trailing-slash-start.test.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,8 @@ | ||
import { runTests } from './utils' | ||
|
||
describe.skip('trailing slash dev', () => { | ||
it.each([{ trailingSlash: false }, { trailingSlash: true }])( | ||
"should work in prod with trailingSlash '$trailingSlash'", | ||
async ({ trailingSlash }) => { | ||
await runTests({ isDev: false, trailingSlash }) | ||
} | ||
) | ||
}) | ||
it.each([{ trailingSlash: false }, { trailingSlash: true }])( | ||
"should work in prod with trailingSlash '$trailingSlash'", | ||
async ({ trailingSlash }) => { | ||
await runTests({ isDev: false, trailingSlash }) | ||
} | ||
) |