Skip to content

Commit

Permalink
test(create-next-app): increase coverage
Browse files Browse the repository at this point in the history
  • Loading branch information
jamesgeorge007 committed Oct 1, 2020
1 parent f06c589 commit dd4a2c6
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions test/integration/create-next-app/index.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -275,4 +275,16 @@ describe('create next app', () => {
}
}, 0o500)
})

it('should create a project in the current directory', async () => {
await usingTempDir(async (cwd) => {
const res = await run(cwd, '.')
expect(res.exitCode).toBe(0)

const files = ['package.json', 'pages/index.js', '.gitignore']
files.forEach((file) =>
expect(fs.existsSync(path.join(cwd, file))).toBeTruthy()
)
})
})
})

0 comments on commit dd4a2c6

Please sign in to comment.