chore: use jiti.import

This commit is contained in:
Daniel Roe 2024-10-17 21:37:59 +01:00
parent 2fa7607c43
commit 7ece49f9b1
No known key found for this signature in database
GPG Key ID: CBC814C393D93268

View File

@ -62,7 +62,7 @@ describe('template', () => {
expect(await formatCss(scopedStyle?.[1] || '')).toMatchSnapshot()
expect(await formatCss(globalStyle?.[1] || '')).toMatchSnapshot()
const { template } = await jiti(`file://${distDir}/${file}.ts`) as { template: () => string }
const { template } = await jiti.import(`file://${distDir}/${file}.ts`) as { template: () => string }
const html = template()
const { valid, results } = await (validator as any).validateString(html)
expect.soft(valid).toBe(true)