diff --git a/lib/build/index.js b/lib/build/index.js index 5d0d571c4d..c62ff33b6d 100644 --- a/lib/build/index.js +++ b/lib/build/index.js @@ -22,6 +22,7 @@ const reqSep = /\//g const sysSep = _.escapeRegExp(sep) const normalize = string => string.replace(reqSep, sysSep) const wp = function (p) { + /* istanbul ignore if */ if (/^win/.test(process.platform)) { p = p.replace(/\\/g, '\\\\') } diff --git a/package.json b/package.json index 16a747e1e1..ea85d6bd54 100644 --- a/package.json +++ b/package.json @@ -35,7 +35,7 @@ "nuxt": "./bin/nuxt" }, "scripts": { - "test": "nyc ava --serial test/", + "test": "nyc ava test/", "coverage": "nyc report --reporter=text-lcov > coverage.lcov && codecov", "lint": "eslint --ext .js,.vue bin lib pages test/*.js --ignore-pattern lib/app", "build": "webpack", diff --git a/test/fixtures/with-config/components/loading.vue b/test/fixtures/with-config/components/loading.vue new file mode 100644 index 0000000000..9c28022726 --- /dev/null +++ b/test/fixtures/with-config/components/loading.vue @@ -0,0 +1,36 @@ + + + + + diff --git a/test/fixtures/with-config/layouts/app.vue b/test/fixtures/with-config/layouts/app.vue new file mode 100644 index 0000000000..25fab4ce30 --- /dev/null +++ b/test/fixtures/with-config/layouts/app.vue @@ -0,0 +1,5 @@ + diff --git a/test/fixtures/with-config/layouts/error.vue b/test/fixtures/with-config/layouts/error.vue new file mode 100644 index 0000000000..7694d81b29 --- /dev/null +++ b/test/fixtures/with-config/layouts/error.vue @@ -0,0 +1,3 @@ + diff --git a/test/fixtures/with-config/nuxt.config.js b/test/fixtures/with-config/nuxt.config.js index 426afb8d18..040ef75068 100644 --- a/test/fixtures/with-config/nuxt.config.js +++ b/test/fixtures/with-config/nuxt.config.js @@ -1,5 +1,7 @@ module.exports = { router: { base: '/test/' - } + }, + cache: true, + loading: '~components/loading' } diff --git a/test/fixtures/with-config/plugins/test.js b/test/fixtures/with-config/plugins/test.js new file mode 100644 index 0000000000..b538bacb75 --- /dev/null +++ b/test/fixtures/with-config/plugins/test.js @@ -0,0 +1 @@ +// Custom plugin