780594f7b6
This ensures when a dependency has a recursive require our should ignore handling doesn't accidentally loop back and forth. x-ref: https://github.com/lovell/sharp/issues/3944 Closes NEXT-2121
22 lines
500 B
TypeScript
22 lines
500 B
TypeScript
import { createNextDescribe } from 'e2e-utils'
|
|
|
|
createNextDescribe(
|
|
'sharp support with hasNextSupport',
|
|
{
|
|
files: __dirname,
|
|
dependencies: {
|
|
sharp: 'latest',
|
|
},
|
|
env: {
|
|
NOW_BUILDER: '1',
|
|
},
|
|
},
|
|
({ next }) => {
|
|
// we're mainly checking if build/start were successful so
|
|
// we have a basic assertion here
|
|
it('should work using cheerio', async () => {
|
|
const $ = await next.render$('/')
|
|
expect($('p').text()).toBe('hello world')
|
|
})
|
|
}
|
|
)
|