Skip to content

Commit ee2cd2f

Browse files
committed
test: tweak
1 parent 3092532 commit ee2cd2f

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

packages/vite/src/node/server/environments/rolldown.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ export function rolldownDevHandleConfig(
4040
if (!config.experimental?.rolldownDev) {
4141
return {}
4242
}
43-
if (env.command === 'build') {
43+
if (env.command === 'build' || env.isPreview) {
4444
delete config.experimental?.rolldownDev
4545
return {}
4646
}

playground/rolldown-dev-react/__tests__/basic.spec.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import { test } from 'vitest'
2-
import { editFile, page, viteTestUrl } from '../../test-utils'
2+
import { editFile, isBuild, page, viteTestUrl } from '../../test-utils'
33

44
test('basic', async () => {
55
await page.getByRole('button', { name: 'Count: 0' }).click()
@@ -10,7 +10,7 @@ test('basic', async () => {
1010
await page.getByText('[alias] test-alias-dest:ok').click()
1111
})
1212

13-
test('hmr', async () => {
13+
test.runIf(!isBuild)('hmr', async () => {
1414
await page.goto(viteTestUrl)
1515
await page.getByRole('button', { name: 'Count: 0' }).click()
1616

0 commit comments

Comments
 (0)