diff --git a/test/integration/react-streaming-and-server-components/test/index.test.js b/test/integration/react-streaming-and-server-components/test/index.test.js index 776171e2464dc0b..658d90e9b5ff8e0 100644 --- a/test/integration/react-streaming-and-server-components/test/index.test.js +++ b/test/integration/react-streaming-and-server-components/test/index.test.js @@ -53,7 +53,7 @@ describe('Edge runtime - errors', () => { it('should warn user that native node APIs are not supported', async () => { const fsImportedErrorMessage = 'Native Node.js APIs are not supported in the Edge Runtime. Found `dns` imported.' - const { stderr } = await nextBuild(nativeModuleTestAppDir) + const { stderr } = await nextBuild(nativeModuleTestAppDir, { stderr: true }) expect(stderr).toContain(fsImportedErrorMessage) }) }) @@ -140,6 +140,7 @@ const edgeRuntimeBasicSuite = { const nodejsRuntimeBasicSuite = { runTests: (context, env) => { const options = { runtime: 'nodejs', env } + const distDir = join(appDir, '.next') basic(context, options) streaming(context, options) rsc(context, options) diff --git a/test/integration/react-streaming-and-server-components/test/rsc.js b/test/integration/react-streaming-and-server-components/test/rsc.js index a7cc18df86b7f54..cb5e0537d15104a 100644 --- a/test/integration/react-streaming-and-server-components/test/rsc.js +++ b/test/integration/react-streaming-and-server-components/test/rsc.js @@ -3,9 +3,10 @@ import webdriver from 'next-webdriver' import { renderViaHTTP, check } from 'next-test-utils' import { join } from 'path' import fs from 'fs-extra' -import { distDir, getNodeBySelector } from './utils' +import { getNodeBySelector } from './utils' export default function (context, { runtime, env }) { + const distDir = join(context.appDir, '.next') it('should render server components correctly', async () => { const homeHTML = await renderViaHTTP(context.appPort, '/', null, { headers: { diff --git a/test/integration/react-streaming-and-server-components/test/switchable-runtime.test.js b/test/integration/react-streaming-and-server-components/test/switchable-runtime.test.js index 9ab6d68d3492fc9..ef4d0e9a4df1421 100644 --- a/test/integration/react-streaming-and-server-components/test/switchable-runtime.test.js +++ b/test/integration/react-streaming-and-server-components/test/switchable-runtime.test.js @@ -50,7 +50,10 @@ describe('Switchable runtime (prod)', () => { beforeAll(async () => { context.appPort = await findPort() - const { stdout, stderr } = await nextBuild(context.appDir) + const { stdout, stderr } = await nextBuild(context.appDir, { + stderr: true, + stdout: true, + }) context.stdout = stdout context.stderr = stderr context.server = await nextStart(context.appDir, context.appPort)