Skip to content

Commit 442807b

Browse files
eps1lonlubieowoce
authored andcommitted
Test lint config after first-time setup (#67146)
1 parent a40bc1f commit 442807b

File tree

5 files changed

+580
-17
lines changed

5 files changed

+580
-17
lines changed

test/integration/eslint/test/next-build.test.js

Lines changed: 0 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@ import { join } from 'path'
44

55
import { nextBuild } from 'next-test-utils'
66

7-
const dirFirstTimeSetup = join(__dirname, '../first-time-setup')
87
const dirCustomConfig = join(__dirname, '../custom-config')
98
const dirIgnoreDuringBuilds = join(__dirname, '../ignore-during-builds')
109
const dirBaseDirectories = join(__dirname, '../base-directories')
@@ -23,22 +22,6 @@ describe('Next Build', () => {
2322
;(process.env.TURBOPACK_DEV ? describe.skip : describe)(
2423
'production mode',
2524
() => {
26-
test('first time setup', async () => {
27-
const eslintrcJson = join(dirFirstTimeSetup, '.eslintrc.json')
28-
await fs.writeFile(eslintrcJson, '')
29-
30-
const { stdout, stderr } = await nextBuild(dirFirstTimeSetup, [], {
31-
stdout: true,
32-
stderr: true,
33-
lint: true,
34-
})
35-
const output = stdout + stderr
36-
37-
expect(output).toContain(
38-
'No ESLint configuration detected. Run next lint to begin setup'
39-
)
40-
})
41-
4225
test('shows warnings and errors', async () => {
4326
const { stdout, stderr } = await nextBuild(dirCustomConfig, [], {
4427
stdout: true,
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
export default function Test() {
2+
return (
3+
<div>
4+
<h1>Hello title</h1>
5+
</div>
6+
)
7+
}
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
export default function Test() {
2+
return (
3+
<div>
4+
<h1>Hello title</h1>
5+
</div>
6+
)
7+
}

0 commit comments

Comments
 (0)