Unverified Commit b0ad8adc authored by JJ Kasper's avatar JJ Kasper Committed by GitHub

Update app-dir E2E tests for deploy (#42269)

x-ref:
https://github.com/vercel/next.js/actions/runs/3364229800/jobs/5579571814

## Bug

- [ ] Related issues linked using `fixes #number`
- [ ] Integration tests added
- [ ] Errors have a helpful link attached, see `contributing.md`

## Feature

- [ ] Implements an existing feature request or RFC. Make sure the
feature request has been accepted for implementation before opening a
PR.
- [ ] Related issues linked using `fixes #number`
- [ ] Integration tests added
- [ ] Documentation added
- [ ] Telemetry added. In case of a feature if it's used or not.
- [ ] Errors have a helpful link attached, see `contributing.md`

## Documentation / Examples

- [ ] Make sure the linting passes by running `pnpm build && pnpm lint`
- [ ] The "examples guidelines" are followed from [our contributing
doc](https://github.com/vercel/next.js/blob/canary/contributing/examples/adding-examples.md)
parent c1c3eac3
...@@ -1182,6 +1182,8 @@ describe('app dir', () => { ...@@ -1182,6 +1182,8 @@ describe('app dir', () => {
expect($('#params-not-real').text()).toBe('N/A') expect($('#params-not-real').text()).toBe('N/A')
}) })
// TODO-APP: correct this behavior when deployed
if (!(global as any).isNextDeploy) {
it('should have the canonical url search params on rewrite', async () => { it('should have the canonical url search params on rewrite', async () => {
const html = await renderViaHTTP( const html = await renderViaHTTP(
next.url, next.url,
...@@ -1193,6 +1195,7 @@ describe('app dir', () => { ...@@ -1193,6 +1195,7 @@ describe('app dir', () => {
expect($('#params-third').text()).toBe('c') expect($('#params-third').text()).toBe('c')
expect($('#params-not-real').text()).toBe('N/A') expect($('#params-not-real').text()).toBe('N/A')
}) })
}
}) })
describe('useRouter', () => { describe('useRouter', () => {
...@@ -2221,6 +2224,8 @@ describe('app dir', () => { ...@@ -2221,6 +2224,8 @@ describe('app dir', () => {
}) })
describe('data fetch with response over 16KB with chunked encoding', () => { describe('data fetch with response over 16KB with chunked encoding', () => {
// TODO-APP: increase timeouts for testing against deploy?
if (!(global as any).isNextDeploy) {
it('should load page when fetching a large amount of data', async () => { it('should load page when fetching a large amount of data', async () => {
const browser = await webdriver(next.url, '/very-large-data-fetch') const browser = await webdriver(next.url, '/very-large-data-fetch')
expect( expect(
...@@ -2233,6 +2238,7 @@ describe('app dir', () => { ...@@ -2233,6 +2238,7 @@ describe('app dir', () => {
await (await browser.waitForElementByCss('#random', 2000)).text() await (await browser.waitForElementByCss('#random', 2000)).text()
).toBe('5') ).toBe('5')
}) })
}
}) })
} }
......
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