Unverified Commit b0706c31 authored by Hendrik Liebau's avatar Hendrik Liebau Committed by GitHub

Disable `rewrite-headers` tests that are dependent on Vercel site config (#75647)

The two scenarios that test rewrite headers for vercel.com are dependent
on how the Vercel site has currently configured its rewrites, and thus
are prone to be flaky. Until we've figured out what Next.js logic this
is supposed to test, and how we can decouple it from this external
source, we are disabling them to unblock other PRs.

An attempt to fix the expectation was done yesterday in #75602, but in
the meantime the returned `x-nextjs-rewritten-path` header has changed
again
(`/home/eyJhbGciOiJIUzI1NiJ9.AP0.7cQg-Q2tj1BAyHFfT32HLI3JRdEfYCiANjbtqRiDfLs`).
parent 879e2797
...@@ -308,31 +308,34 @@ const cases: { ...@@ -308,31 +308,34 @@ const cases: {
'x-nextjs-rewritten-query': null, 'x-nextjs-rewritten-query': null,
}, },
}, },
{ // TODO: These next two scenarios are dependent on how the Vercel site has
name: 'middleware rewrite external RSC', // configured its rewrites, and thus are prone to be flaky. Figure out what
pathname: '/hello/vercel', // Next.js logic this is supposed to test.
headers: { // {
RSC: '1', // name: 'middleware rewrite external RSC',
}, // pathname: '/hello/vercel',
expected: { // headers: {
// Vercel matches `/` to `/home` // RSC: '1',
'x-nextjs-rewritten-path': '/home', // },
'x-nextjs-rewritten-query': null, // expected: {
}, // // Vercel matches `/` to `/home`
}, // 'x-nextjs-rewritten-path': '/home',
{ // 'x-nextjs-rewritten-query': null,
name: 'middleware rewrite external Prefetch RSC', // },
pathname: '/hello/vercel', // },
headers: { // {
RSC: '1', // name: 'middleware rewrite external Prefetch RSC',
'Next-Router-Prefetch': '1', // pathname: '/hello/vercel',
}, // headers: {
expected: { // RSC: '1',
// Vercel matches `/` to `/home` // 'Next-Router-Prefetch': '1',
'x-nextjs-rewritten-path': '/home', // },
'x-nextjs-rewritten-query': null, // expected: {
}, // // Vercel matches `/` to `/home`
}, // 'x-nextjs-rewritten-path': '/home',
// 'x-nextjs-rewritten-query': null,
// },
// },
{ {
name: 'next.config.js rewrites with query HTML', name: 'next.config.js rewrites with query HTML',
pathname: '/hello/fred', pathname: '/hello/fred',
......
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