Skip to content

Commit

Permalink
Skip webpack specific test
Browse files Browse the repository at this point in the history
  • Loading branch information
timneutkens committed Oct 16, 2023
1 parent 73c7f24 commit bca73ec
Showing 1 changed file with 31 additions and 24 deletions.
55 changes: 31 additions & 24 deletions test/integration/next-dynamic-lazy-compilation/test/index.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -46,31 +46,38 @@ function runTests() {
})
}

describe('next/dynamic', () => {
describe('dev mode', () => {
beforeAll(async () => {
appPort = await findPort()
app = await launchApp(appDir, appPort)
})
afterAll(() => killApp(app))

runTests(true)
})
;(process.env.TURBOPACK ? describe.skip : describe)('production mode', () => {
beforeAll(async () => {
await runNextCommand(['build', appDir])

app = nextServer({
dir: appDir,
dev: false,
quiet: true,
// This test is not needed for Turbopack as it relies on an experimental webpack feature.
;(process.env.TURBOPACK ? describe.skip : describe)(
'next/dynamic lazy compilation',
() => {
describe('dev mode', () => {
beforeAll(async () => {
appPort = await findPort()
app = await launchApp(appDir, appPort)
})
afterAll(() => killApp(app))

server = await startApp(app)
appPort = server.address().port
runTests(true)
})
afterAll(() => stopApp(server))
;(process.env.TURBOPACK ? describe.skip : describe)(
'production mode',
() => {
beforeAll(async () => {
await runNextCommand(['build', appDir])

runTests()
})
})
app = nextServer({
dir: appDir,
dev: false,
quiet: true,
})

server = await startApp(app)
appPort = server.address().port
})
afterAll(() => stopApp(server))

runTests()
}
)
}
)

0 comments on commit bca73ec

Please sign in to comment.