diff --git a/packages/cna-template/template/frameworks/ava/test/e2e/index.spec.js b/packages/cna-template/template/frameworks/ava/test/e2e/index.spec.js index 01d599325..f190b2490 100644 --- a/packages/cna-template/template/frameworks/ava/test/e2e/index.spec.js +++ b/packages/cna-template/template/frameworks/ava/test/e2e/index.spec.js @@ -1,6 +1,7 @@ import { resolve } from 'path' import test from 'ava' import { Nuxt, Builder } from 'nuxt' +import config from '../../nuxt.config' // We keep the nuxt and server instance // So we can close them at the end of the test @@ -8,11 +9,11 @@ let nuxt = null // Init Nuxt.js and create a server listening on localhost:4000 test.before(async () => { - const config = { + nuxt = new Nuxt({ + ...config, dev: false, rootDir: resolve(__dirname, '../../') - } - nuxt = new Nuxt(config) + }) await new Builder(nuxt).build() await nuxt.server.listen(4000, 'localhost') }, 30000)