mirror of
https://github.com/nuxt/nuxt.git
synced 2024-11-11 08:33:53 +00:00
Ignore webpack midd for tests
This commit is contained in:
parent
38ef413e5d
commit
957e730bc4
@ -116,6 +116,7 @@ exports.build = function * () {
|
|||||||
/*
|
/*
|
||||||
** Generate .nuxt/dist/ files
|
** Generate .nuxt/dist/ files
|
||||||
*/
|
*/
|
||||||
|
/* istanbul ignore if */
|
||||||
if (this.dev) {
|
if (this.dev) {
|
||||||
debug('Adding webpack middlewares...')
|
debug('Adding webpack middlewares...')
|
||||||
createWebpackMiddlewares.call(this)
|
createWebpackMiddlewares.call(this)
|
||||||
@ -254,6 +255,7 @@ function getWebpackServerConfig () {
|
|||||||
return serverWebpackConfig.call(this)
|
return serverWebpackConfig.call(this)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* istanbul ignore next */
|
||||||
function createWebpackMiddlewares () {
|
function createWebpackMiddlewares () {
|
||||||
const clientConfig = getWebpackClientConfig.call(this)
|
const clientConfig = getWebpackClientConfig.call(this)
|
||||||
// setup on the fly compilation + hot-reload
|
// setup on the fly compilation + hot-reload
|
||||||
@ -276,6 +278,7 @@ function createWebpackMiddlewares () {
|
|||||||
this.webpackHotMiddleware = pify(require('webpack-hot-middleware')(clientCompiler))
|
this.webpackHotMiddleware = pify(require('webpack-hot-middleware')(clientCompiler))
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* istanbul ignore next */
|
||||||
function webpackWatchAndUpdate () {
|
function webpackWatchAndUpdate () {
|
||||||
const MFS = require('memory-fs') // <- dependencies of webpack
|
const MFS = require('memory-fs') // <- dependencies of webpack
|
||||||
const mfs = new MFS()
|
const mfs = new MFS()
|
||||||
@ -338,6 +341,7 @@ function createRenderer (bundle) {
|
|||||||
this.renderToStream = this.renderer.renderToStream
|
this.renderToStream = this.renderer.renderToStream
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* istanbul ignore next */
|
||||||
function watchPages () {
|
function watchPages () {
|
||||||
const patterns = [ r(this.srcDir, 'pages/*.vue'), r(this.srcDir, 'pages/**/*.vue') ]
|
const patterns = [ r(this.srcDir, 'pages/*.vue'), r(this.srcDir, 'pages/**/*.vue') ]
|
||||||
const options = {
|
const options = {
|
||||||
|
Loading…
Reference in New Issue
Block a user