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

Function getStderr

test/integration/data-fetching-errors/test/index.test.ts:27–43  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

25
26const runTests = (isDev = false) => {
27 const getStderr = async () => {
28 if (isDev) {
29 let stderr = ''
30 appPort = await findPort()
31 app = await launchApp(appDir, appPort, {
32 onStderr(msg) {
33 stderr += msg || ''
34 },
35 })
36 await renderViaHTTP(appPort, '/')
37 await killApp(app)
38 return stderr
39 } else {
40 const { stderr } = await nextBuild(appDir, undefined, { stderr: true })
41 return stderr
42 }
43 }
44
45 it('should show error for getStaticProps as component member', async () => {
46 await fs.writeFile(

Callers 3

runTestsFunction · 0.85
runTestsFunction · 0.85
runTestsFunction · 0.85

Calls 5

findPortFunction · 0.90
launchAppFunction · 0.90
renderViaHTTPFunction · 0.90
killAppFunction · 0.90
nextBuildFunction · 0.90

Tested by

no test coverage detected