mirror of
https://github.com/nuxt/nuxt.git
synced 2024-11-30 09:27:13 +00:00
test for nuxt.js
This commit is contained in:
parent
b74d452f23
commit
38ef413e5d
@ -84,18 +84,21 @@ class Nuxt {
|
|||||||
|
|
||||||
close (callback) {
|
close (callback) {
|
||||||
let promises = []
|
let promises = []
|
||||||
|
/* istanbul ignore if */
|
||||||
if (this.webpackDevMiddleware) {
|
if (this.webpackDevMiddleware) {
|
||||||
const p = new Promise((resolve, reject) => {
|
const p = new Promise((resolve, reject) => {
|
||||||
this.webpackDevMiddleware.close(() => resolve())
|
this.webpackDevMiddleware.close(() => resolve())
|
||||||
})
|
})
|
||||||
promises.push(p)
|
promises.push(p)
|
||||||
}
|
}
|
||||||
|
/* istanbul ignore if */
|
||||||
if (this.webpackServerWatcher) {
|
if (this.webpackServerWatcher) {
|
||||||
const p = new Promise((resolve, reject) => {
|
const p = new Promise((resolve, reject) => {
|
||||||
this.webpackServerWatcher.close(() => resolve())
|
this.webpackServerWatcher.close(() => resolve())
|
||||||
})
|
})
|
||||||
promises.push(p)
|
promises.push(p)
|
||||||
}
|
}
|
||||||
|
/* istanbul ignore if */
|
||||||
if (this.pagesFilesWatcher) {
|
if (this.pagesFilesWatcher) {
|
||||||
this.pagesFilesWatcher.close()
|
this.pagesFilesWatcher.close()
|
||||||
}
|
}
|
||||||
|
17
test/fixtures/with-config/store/index.js
vendored
Normal file
17
test/fixtures/with-config/store/index.js
vendored
Normal file
@ -0,0 +1,17 @@
|
|||||||
|
import Vue from 'vue'
|
||||||
|
import Vuex from 'vuex'
|
||||||
|
|
||||||
|
Vue.use(Vuex)
|
||||||
|
|
||||||
|
const store = new Vuex.Store({
|
||||||
|
state: {
|
||||||
|
counter: 0
|
||||||
|
},
|
||||||
|
mutations: {
|
||||||
|
increment (state) {
|
||||||
|
state.counter++
|
||||||
|
}
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
export default store
|
Loading…
Reference in New Issue
Block a user