Skip to content

Commit

Permalink
Fix fixture
Browse files Browse the repository at this point in the history
  • Loading branch information
mischnic committed Dec 10, 2024
1 parent 9fb681a commit aa18202
Showing 1 changed file with 9 additions and 2 deletions.
11 changes: 9 additions & 2 deletions test/development/pages-dir/client-navigation/rendering.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -225,15 +225,22 @@ describe('Client Navigation rendering', () => {

const buildManifest = await next.readJSON(`.next/${BUILD_MANIFEST}`)
const reactLoadableManifest = await next.readJSON(
`.next/${REACT_LOADABLE_MANIFEST}`
process.env.TURBOPACK
? `.next/server/pages/dynamic/ssr/${REACT_LOADABLE_MANIFEST}`
: `.next/${REACT_LOADABLE_MANIFEST}`
)
const resources = []

const manifestKey = Object.keys(reactLoadableManifest).find((item) => {
return item
.replace(/\\/g, '/')
.endsWith('ssr.js -> ../../components/hello1')
.endsWith(
process.env.TURBOPACK
? 'components/hello1.js [client] (ecmascript, next/dynamic entry)'
: 'ssr.js -> ../../components/hello1'
)
})
expect(manifestKey).toBeString()

// test dynamic chunk
resources.push('/_next/' + reactLoadableManifest[manifestKey].files[0])
Expand Down

0 comments on commit aa18202

Please sign in to comment.