Files
next.js/test/development/project-directory-with-styled-jsx-suffix/index.test.ts
Niklas MischkulnigandGitHub 589065d788 Fix flakey multiple-lockfiles tests (#83103)
Writing to `join(next.testDir, '../package-lock.json')` breaks test isolation.
2025-08-27 15:46:53 +02:00

27 lines
645 B
TypeScript

import { createNext } from 'e2e-utils'
import { NextInstance } from 'e2e-utils'
import { renderViaHTTP } from 'next-test-utils'
describe('project directory with styled-jsx suffix', () => {
let next: NextInstance
beforeAll(async () => {
next = await createNext({
files: {
'pages/index.js': `
export default function Page() {
return <p>hello world</p>
}
`,
},
subDir: 'test-styled-jsx',
})
})
afterAll(() => next.destroy())
it('should work', async () => {
const html = await renderViaHTTP(next.url, '/')
expect(html).toContain('hello world')
})
})