MCPcopy
hub / github.com/vercel/next.js / withInvocationId

Function withInvocationId

test/lib/next-test-utils.ts:239–248  ·  view source on GitHub ↗
(opts?: RequestInit)

Source from the content-addressed store, hash-verified

237 * @returns RequestInit with x-invocation-id header added
238 */
239export function withInvocationId(opts?: RequestInit): RequestInit {
240 const invocationId = `test:${nanoid()}`
241 return {
242 ...opts,
243 headers: {
244 ...opts?.headers,
245 'x-invocation-id': invocationId,
246 },
247 }
248}
249
250export function renderViaHTTP(
251 appPort: string | number,

Calls 1

nanoidFunction · 0.90

Tested by

no test coverage detected