mirror of
https://github.com/nuxt/nuxt.git
synced 2024-12-18 02:07:14 +00:00
21 lines
490 B
JavaScript
21 lines
490 B
JavaScript
import { NuxtCommand, commands } from '@nuxt/cli'
|
|
import consola from 'consola'
|
|
|
|
describe('cli build', () => {
|
|
test('nuxt build', async () => {
|
|
const buildCommand = await commands.default('build')
|
|
|
|
const argv = [
|
|
__dirname,
|
|
'--no-force-exit',
|
|
'-c',
|
|
'cli.build.config.js'
|
|
]
|
|
|
|
const cmd = new NuxtCommand(buildCommand, argv)
|
|
await expect(cmd.run()).resolves.toBeUndefined()
|
|
|
|
expect(consola.log).toBeCalledWith('Compiled successfully')
|
|
})
|
|
})
|