silverwolf-x's picture
download
raw
806 Bytes
import { nextTestSetup } from 'e2e-utils'
import stripAnsi from 'strip-ansi'
describe('build-error-logs', () => {
const { next, isTurbopack, isRspack } = nextTestSetup({
files: __dirname,
})
it('should only log error a single time', async () => {
await next.fetch('/')
const output = stripAnsi(next.cliOutput)
expect(output).toContain('Module not found')
const moduleNotFoundLogs = output
.split('\n')
.filter((line) => line.includes('Module not found'))
if (isTurbopack) {
expect(moduleNotFoundLogs).toHaveLength(1)
} else if (isRspack) {
expect([2, 3]).toContain(moduleNotFoundLogs.length)
} else {
// FIXME: next with webpack still logs the same error too many times
expect(moduleNotFoundLogs).toHaveLength(3)
}
})
})

Xet Storage Details

Size:
806 Bytes
·
Xet hash:
c83c589e8c99bb9b09f5243f097f5025535a13446a874f8ea2979d23b69966b2

Xet efficiently stores files, intelligently splitting them into unique chunks and accelerating uploads and downloads. More info.