mirror of
https://github.com/nuxt/nuxt.git
synced 2025-01-28 22:32:42 +00:00
chore: update tests
This commit is contained in:
parent
b16060afd4
commit
68326a6c9b
@ -6,7 +6,6 @@ test('Fail with routes() which throw an error', async t => {
|
||||
const options = {
|
||||
rootDir: resolve(__dirname, 'fixtures/basic'),
|
||||
dev: false,
|
||||
runBuild: true,
|
||||
generate: {
|
||||
async routes () {
|
||||
throw new Error('Not today!')
|
||||
|
@ -18,7 +18,6 @@ test.before('Init Nuxt.js', async t => {
|
||||
let config = require(resolve(rootDir, 'nuxt.config.js'))
|
||||
config.rootDir = rootDir
|
||||
config.dev = false
|
||||
config.runBuild = true
|
||||
nuxt = new Nuxt(config)
|
||||
const builder = new Builder(nuxt)
|
||||
const generator = new Generator(nuxt, builder)
|
||||
|
@ -13,8 +13,7 @@ let nuxt = null
|
||||
test.before('Init Nuxt.js', async t => {
|
||||
const options = {
|
||||
rootDir: resolve(__dirname, 'fixtures/basic'),
|
||||
dev: false,
|
||||
runBuild: true
|
||||
dev: false
|
||||
}
|
||||
nuxt = new Nuxt(options)
|
||||
await new Builder(nuxt).build()
|
||||
|
@ -11,8 +11,7 @@ let nuxt = null
|
||||
test.before('Init Nuxt.js', async t => {
|
||||
const options = {
|
||||
rootDir: resolve(__dirname, 'fixtures/children'),
|
||||
dev: false,
|
||||
runBuild: true
|
||||
dev: false
|
||||
}
|
||||
nuxt = new Nuxt(options)
|
||||
await new Builder(nuxt).build()
|
||||
|
@ -9,8 +9,7 @@ const readFile = pify(fs.readFile)
|
||||
test.before('Init Nuxt.js', async t => {
|
||||
const nuxt = new Nuxt({
|
||||
rootDir: resolve(__dirname, 'fixtures/dynamic-routes'),
|
||||
dev: false,
|
||||
runBuild: true
|
||||
dev: false
|
||||
})
|
||||
await new Builder(nuxt).build()
|
||||
})
|
||||
|
@ -11,8 +11,7 @@ let nuxt = null
|
||||
test.before('Init Nuxt.js', async t => {
|
||||
const options = {
|
||||
rootDir: resolve(__dirname, 'fixtures/error'),
|
||||
dev: false,
|
||||
runBuild: true
|
||||
dev: false
|
||||
}
|
||||
nuxt = new Nuxt(options)
|
||||
await new Builder(nuxt).build()
|
||||
|
@ -14,8 +14,7 @@ let app
|
||||
test.before('Init Nuxt.js', async t => {
|
||||
const options = {
|
||||
rootDir: resolve(__dirname, 'fixtures/basic'),
|
||||
dev: false,
|
||||
runBuild: true
|
||||
dev: false
|
||||
}
|
||||
|
||||
// Create nuxt instace
|
||||
|
@ -20,7 +20,6 @@ test.serial('Nuxt.js Instance', async t => {
|
||||
test.serial('Fail to build when no pages/ directory but is in the parent', t => {
|
||||
const nuxt = new Nuxt({
|
||||
dev: false,
|
||||
runBuild: true,
|
||||
rootDir: resolve(__dirname, 'fixtures', 'empty', 'pages')
|
||||
})
|
||||
return new Builder(nuxt).build().catch(err => {
|
||||
@ -33,7 +32,6 @@ test.serial('Fail to build when no pages/ directory but is in the parent', t =>
|
||||
test.serial('Fail to build when no pages/ directory', t => {
|
||||
const nuxt = new Nuxt({
|
||||
dev: false,
|
||||
runBuild: true,
|
||||
rootDir: resolve(__dirname)
|
||||
})
|
||||
return new Builder(nuxt).build().catch(err => {
|
||||
|
@ -14,7 +14,6 @@ test.before('Init Nuxt.js', async t => {
|
||||
let config = require(resolve(rootDir, 'nuxt.config.js'))
|
||||
config.rootDir = rootDir
|
||||
config.dev = false
|
||||
config.runBuild = true
|
||||
nuxt = new Nuxt(config)
|
||||
await new Builder(nuxt).build()
|
||||
|
||||
|
@ -14,7 +14,6 @@ test.before('Init Nuxt.js', async t => {
|
||||
let config = require(resolve(rootDir, 'nuxt.config.js'))
|
||||
config.rootDir = rootDir
|
||||
config.dev = false
|
||||
config.runBuild = true
|
||||
nuxt = new Nuxt(config)
|
||||
await new Builder(nuxt).build()
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user