|
8 | 8 | getColor,
|
9 | 9 | isBuild,
|
10 | 10 | isServe,
|
11 |
| - isWindows, |
12 | 11 | listAssets,
|
13 | 12 | notifyRebuildComplete,
|
14 | 13 | page,
|
@@ -634,35 +633,31 @@ test.runIf(isBuild)('manifest', async () => {
|
634 | 633 | }
|
635 | 634 | })
|
636 | 635 |
|
637 |
| -// TODO: skip on Windows due to https://github.com/rolldown/rolldown/issues/4385 |
638 |
| -describe.runIf(isBuild && !isWindows)( |
639 |
| - 'css and assets in css in build watch', |
640 |
| - () => { |
641 |
| - test('css will not be lost and css does not contain undefined', async () => { |
642 |
| - editFile('index.html', (code) => code.replace('Assets', 'assets')) |
643 |
| - await notifyRebuildComplete(watcher) |
644 |
| - const cssFile = findAssetFile(/index-[-\w]+\.css$/, 'foo') |
645 |
| - expect(cssFile).not.toBe('') |
646 |
| - expect(cssFile).not.toMatch(/undefined/) |
647 |
| - }) |
| 636 | +describe.runIf(isBuild)('css and assets in css in build watch', () => { |
| 637 | + test('css will not be lost and css does not contain undefined', async () => { |
| 638 | + editFile('index.html', (code) => code.replace('Assets', 'assets')) |
| 639 | + await notifyRebuildComplete(watcher) |
| 640 | + const cssFile = findAssetFile(/index-[-\w]+\.css$/, 'foo') |
| 641 | + expect(cssFile).not.toBe('') |
| 642 | + expect(cssFile).not.toMatch(/undefined/) |
| 643 | + }) |
648 | 644 |
|
649 |
| - test('import module.css', async () => { |
650 |
| - expect(await getColor('#foo')).toBe('red') |
651 |
| - editFile('css/foo.module.css', (code) => code.replace('red', 'blue')) |
652 |
| - await notifyRebuildComplete(watcher) |
653 |
| - await page.reload() |
654 |
| - expect(await getColor('#foo')).toBe('blue') |
655 |
| - }) |
| 645 | + test('import module.css', async () => { |
| 646 | + expect(await getColor('#foo')).toBe('red') |
| 647 | + editFile('css/foo.module.css', (code) => code.replace('red', 'blue')) |
| 648 | + await notifyRebuildComplete(watcher) |
| 649 | + await page.reload() |
| 650 | + expect(await getColor('#foo')).toBe('blue') |
| 651 | + }) |
656 | 652 |
|
657 |
| - test('import with raw query', async () => { |
658 |
| - expect(await page.textContent('.raw-query')).toBe('foo') |
659 |
| - editFile('static/foo.txt', (code) => code.replace('foo', 'zoo')) |
660 |
| - await notifyRebuildComplete(watcher) |
661 |
| - await page.reload() |
662 |
| - expect(await page.textContent('.raw-query')).toBe('zoo') |
663 |
| - }) |
664 |
| - }, |
665 |
| -) |
| 653 | + test('import with raw query', async () => { |
| 654 | + expect(await page.textContent('.raw-query')).toBe('foo') |
| 655 | + editFile('static/foo.txt', (code) => code.replace('foo', 'zoo')) |
| 656 | + await notifyRebuildComplete(watcher) |
| 657 | + await page.reload() |
| 658 | + expect(await page.textContent('.raw-query')).toBe('zoo') |
| 659 | + }) |
| 660 | +}) |
666 | 661 |
|
667 | 662 | test('inline style test', async () => {
|
668 | 663 | expect(await getBg('.inline-style')).toMatch(assetMatch)
|
|
0 commit comments