Update dependencies
This commit is contained in:
commit
812c3a1edd
@ -1 +1 @@
|
|||||||
chrome 79
|
chrome 80
|
||||||
|
@ -6,9 +6,11 @@ NW.js + Vue-CLI 4 example
|
|||||||
|
|
||||||
![A screenshot of the default app running on Windows](screenshot.png)
|
![A screenshot of the default app running on Windows](screenshot.png)
|
||||||
|
|
||||||
* NW.js
|
* NW.js 0.44.2
|
||||||
* Vue-CLI 4
|
* Chrome 80
|
||||||
* Vue 2.6
|
* Node 13.8.0
|
||||||
|
* Vue-CLI 4.2.2
|
||||||
|
* Vue 2.6.11
|
||||||
* Vue-DevTools (latest)
|
* Vue-DevTools (latest)
|
||||||
* Babel
|
* Babel
|
||||||
* ESLint
|
* ESLint
|
||||||
@ -88,5 +90,6 @@ This is not for those *using* this repo, but for those *maintaining* it.
|
|||||||
* `tests/unit/setup.js`
|
* `tests/unit/setup.js`
|
||||||
* `tests/unit/components/__snapshots__/HelloWorld.test.js.snap`
|
* `tests/unit/components/__snapshots__/HelloWorld.test.js.snap`
|
||||||
* `.browserslistrc`
|
* `.browserslistrc`
|
||||||
|
1. Update the version numbers at the top of the README
|
||||||
1. Bump the version number, and all the npm scripts that reference the version number
|
1. Bump the version number, and all the npm scripts that reference the version number
|
||||||
1. Run `npm run regression` after updating dependencies or other major changes to verify builds still work correctly
|
1. Run `npm run regression` after updating dependencies or other major changes to verify builds still work correctly
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
module.exports = {
|
module.exports = {
|
||||||
presets: [
|
presets: [
|
||||||
'@vue/app'
|
'@vue/cli-plugin-babel/preset'
|
||||||
]
|
]
|
||||||
};
|
};
|
||||||
|
@ -2,45 +2,18 @@ process.env.VUE_CLI_BABEL_TARGET_NODE = true;
|
|||||||
process.env.VUE_CLI_BABEL_TRANSPILE_MODULES = true;
|
process.env.VUE_CLI_BABEL_TRANSPILE_MODULES = true;
|
||||||
|
|
||||||
module.exports = {
|
module.exports = {
|
||||||
collectCoverageFrom: [
|
preset: '@vue/cli-plugin-unit-jest',
|
||||||
'src/**/*.{js,vue}',
|
|
||||||
'!src/main.js',
|
|
||||||
'!**/node_modules/**'
|
|
||||||
],
|
|
||||||
coverageDirectory: '<rootDir>/tests/unit/coverage',
|
coverageDirectory: '<rootDir>/tests/unit/coverage',
|
||||||
moduleFileExtensions: [
|
|
||||||
'js',
|
|
||||||
'jsx',
|
|
||||||
'json',
|
|
||||||
'vue'
|
|
||||||
],
|
|
||||||
moduleNameMapper: {
|
|
||||||
'^@/(.*)$': '<rootDir>/src/$1'
|
|
||||||
},
|
|
||||||
setupFilesAfterEnv: [
|
setupFilesAfterEnv: [
|
||||||
'<rootDir>/tests/unit/setup.js'
|
'<rootDir>/tests/unit/setup.js'
|
||||||
],
|
],
|
||||||
snapshotSerializers: [
|
snapshotSerializers: [
|
||||||
'<rootDir>/node_modules/jest-serializer-vue-tjw'
|
'<rootDir>/node_modules/jest-serializer-vue-tjw'
|
||||||
],
|
],
|
||||||
testEnvironment: 'jest-environment-jsdom-global',
|
|
||||||
testMatch: [
|
testMatch: [
|
||||||
'**/tests/unit/**/*.test.js'
|
'**/tests/unit/**/*.test.js'
|
||||||
],
|
],
|
||||||
testPathIgnorePatterns: [
|
testPathIgnorePatterns: [
|
||||||
'<rootDir>/tests/e2e'
|
'<rootDir>/tests/e2e'
|
||||||
],
|
|
||||||
testURL: 'http://localhost/',
|
|
||||||
transform: {
|
|
||||||
'^.+\\.vue$': 'vue-jest',
|
|
||||||
'.+\\.(css|styl|less|sass|scss|svg|png|jpg|ttf|woff|woff2)$': 'jest-transform-stub',
|
|
||||||
'^.+\\.jsx?$': 'babel-jest'
|
|
||||||
},
|
|
||||||
transformIgnorePatterns: [
|
|
||||||
'/node_modules/'
|
|
||||||
],
|
|
||||||
watchPlugins: [
|
|
||||||
'jest-watch-typeahead/filename',
|
|
||||||
'jest-watch-typeahead/testname'
|
|
||||||
]
|
]
|
||||||
};
|
};
|
||||||
|
5657
package-lock.json
generated
5657
package-lock.json
generated
File diff suppressed because it is too large
Load Diff
48
package.json
48
package.json
@ -6,7 +6,7 @@
|
|||||||
"To turn spell checking off, remove it from the chromium-args in this file"
|
"To turn spell checking off, remove it from the chromium-args in this file"
|
||||||
],
|
],
|
||||||
"name": "nw-vue",
|
"name": "nw-vue",
|
||||||
"version": "1.4.0",
|
"version": "1.5.0",
|
||||||
"main": "http://localhost:8964",
|
"main": "http://localhost:8964",
|
||||||
"node-remote": "http://localhost:8964",
|
"node-remote": "http://localhost:8964",
|
||||||
"node-main": "",
|
"node-main": "",
|
||||||
@ -27,10 +27,10 @@
|
|||||||
"build:nw": "build --concurrent --tasks win-x86,linux-x86,linux-x64,mac-x64 --mirror https://dl.nwjs.io/ .",
|
"build:nw": "build --concurrent --tasks win-x86,linux-x86,linux-x64,mac-x64 --mirror https://dl.nwjs.io/ .",
|
||||||
"build:win": "npm run build:win:clean && npm run build:vue && build --tasks win-x86 --mirror https://dl.nwjs.io/ .",
|
"build:win": "npm run build:win:clean && npm run build:vue && build --tasks win-x86 --mirror https://dl.nwjs.io/ .",
|
||||||
"build:lin": "npm run build:lin:clean && npm run build:vue && build --tasks linux-x64 --mirror https://dl.nwjs.io/ .",
|
"build:lin": "npm run build:lin:clean && npm run build:vue && build --tasks linux-x64 --mirror https://dl.nwjs.io/ .",
|
||||||
"build:win:clean": "rimraf ./dist-vue ./dist/nw-vue-1.4.0-win-x86 ./dist/nw-vue-1.4.0-win-x86.zip ./dist/nw-vue-1.4.0-win-x86.7z ./dist/nw-vue-1.4.0-win-x86-Setup.exe",
|
"build:win:clean": "rimraf ./dist-vue ./dist/nw-vue-1.5.0-win-x86 ./dist/nw-vue-1.5.0-win-x86.zip ./dist/nw-vue-1.5.0-win-x86.7z ./dist/nw-vue-1.5.0-win-x86-Setup.exe",
|
||||||
"build:lin:clean": "rimraf ./dist-vue ./dist/nw-vue-1.4.0-linux-x64 ./dist/nw-vue-1.4.0-linux-x64.zip",
|
"build:lin:clean": "rimraf ./dist-vue ./dist/nw-vue-1.5.0-linux-x64 ./dist/nw-vue-1.5.0-linux-x64.zip",
|
||||||
"run:win": "dist\\nw-vue-1.4.0-win-x86\\nw-vue.exe",
|
"run:win": "dist\\nw-vue-1.5.0-win-x86\\nw-vue.exe",
|
||||||
"run:lin": "./dist/nw-vue-1.4.0-linux-x64/nw-vue",
|
"run:lin": "./dist/nw-vue-1.5.0-linux-x64/nw-vue",
|
||||||
"regression": "rd /s /q node_modules & rd /s /q node_modules & rd /s /q node_modules & npm install && npm run lint && npm test && npm run build:win && npm run run:win",
|
"regression": "rd /s /q node_modules & rd /s /q node_modules & rd /s /q node_modules & npm install && npm run lint && npm test && npm run build:win && npm run run:win",
|
||||||
"lint": "vue-cli-service lint --no-fix",
|
"lint": "vue-cli-service lint --no-fix",
|
||||||
"fix": "vue-cli-service lint --fix",
|
"fix": "vue-cli-service lint --fix",
|
||||||
@ -44,46 +44,34 @@
|
|||||||
"express": "^4.17.1"
|
"express": "^4.17.1"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@vue/cli-plugin-babel": "^4.1.2",
|
"@vue/cli-plugin-babel": "^4.2.2",
|
||||||
"@vue/cli-plugin-e2e-nightwatch": "^4.1.2",
|
"@vue/cli-plugin-e2e-nightwatch": "^4.2.2",
|
||||||
"@vue/cli-plugin-eslint": "^4.1.2",
|
"@vue/cli-plugin-eslint": "^4.2.2",
|
||||||
"@vue/cli-plugin-unit-jest": "^4.1.2",
|
"@vue/cli-plugin-unit-jest": "^4.2.2",
|
||||||
"@vue/cli-service": "^4.1.2",
|
"@vue/cli-service": "^4.2.2",
|
||||||
"@vue/test-utils": "1.0.0-beta.29",
|
"@vue/test-utils": "1.0.0-beta.31",
|
||||||
"babel-core": "7.0.0-bridge.0",
|
|
||||||
"babel-eslint": "^10.0.3",
|
"babel-eslint": "^10.0.3",
|
||||||
"babel-jest": "^24.9.0",
|
"concurrently": "^5.1.0",
|
||||||
"babel-plugin-dynamic-import-node": "^2.3.0",
|
|
||||||
"babel-plugin-transform-runtime": "^6.23.0",
|
|
||||||
"babel-preset-env": "^1.7.0",
|
|
||||||
"babel-preset-stage-2": "^6.24.1",
|
|
||||||
"babel-preset-vue-app": "^2.0.0",
|
|
||||||
"concurrently": "^5.0.2",
|
|
||||||
"core-js": "^3.6.4",
|
"core-js": "^3.6.4",
|
||||||
"eslint": "^6.8.0",
|
"eslint": "^6.8.0",
|
||||||
"eslint-config-tjw-base": "^1.0.0",
|
"eslint-config-tjw-base": "^1.0.0",
|
||||||
"eslint-config-tjw-vue": "^1.0.0",
|
"eslint-config-tjw-vue": "^1.0.0",
|
||||||
"eslint-plugin-jest": "^23.6.0",
|
"eslint-plugin-jest": "^23.7.0",
|
||||||
"eslint-plugin-vue": "^6.1.2",
|
"eslint-plugin-vue": "^6.2.1",
|
||||||
"eslint-plugin-vue-a11y": "^0.0.31",
|
"eslint-plugin-vue-a11y": "^0.0.31",
|
||||||
"jest": "^24.9.0",
|
"jest-serializer-vue-tjw": "^3.11.0",
|
||||||
"jest-environment-jsdom": "^24.9.0",
|
"nw": "0.44.2-sdk",
|
||||||
"jest-environment-jsdom-global": "^1.2.0",
|
|
||||||
"jest-serializer-vue-tjw": "^3.3.0",
|
|
||||||
"jest-transform-stub": "^2.0.0",
|
|
||||||
"nw": "0.43.6-sdk",
|
|
||||||
"nw-vue-devtools-prebuilt": "^0.0.10",
|
"nw-vue-devtools-prebuilt": "^0.0.10",
|
||||||
"nwjs-builder-phoenix": "^1.15.0",
|
"nwjs-builder-phoenix": "^1.15.0",
|
||||||
"nwjs-types": "^1.0.0",
|
"nwjs-types": "^1.0.0",
|
||||||
"rimraf": "^3.0.0",
|
"rimraf": "^3.0.2",
|
||||||
"vue": "^2.6.11",
|
"vue": "^2.6.11",
|
||||||
"vue-jest": "^3.0.5",
|
|
||||||
"vue-template-compiler": "^2.6.11",
|
"vue-template-compiler": "^2.6.11",
|
||||||
"wait-on": "^4.0.0"
|
"wait-on": "^4.0.0"
|
||||||
},
|
},
|
||||||
"chromium-args": "--enable-spell-checking --load-extension='./node_modules/nw-vue-devtools-prebuilt/extension'",
|
"chromium-args": "--enable-spell-checking --load-extension='./node_modules/nw-vue-devtools-prebuilt/extension'",
|
||||||
"build": {
|
"build": {
|
||||||
"nwVersion": "v0.43.6",
|
"nwVersion": "v0.44.2",
|
||||||
"nwFlavor": "normal",
|
"nwFlavor": "normal",
|
||||||
"targets": [
|
"targets": [
|
||||||
"zip",
|
"zip",
|
||||||
|
@ -5,7 +5,7 @@ describe('App.vue', () => {
|
|||||||
test('Render default contents', () => {
|
test('Render default contents', () => {
|
||||||
const wrapper = shallowMount(App);
|
const wrapper = shallowMount(App);
|
||||||
|
|
||||||
expect(wrapper.html())
|
expect(wrapper)
|
||||||
.toMatchSnapshot();
|
.toMatchSnapshot();
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
@ -5,23 +5,25 @@ describe('FsExample.vue', () => {
|
|||||||
test('Render default contents', () => {
|
test('Render default contents', () => {
|
||||||
const wrapper = shallowMount(FsExample);
|
const wrapper = shallowMount(FsExample);
|
||||||
|
|
||||||
expect(wrapper.html())
|
expect(wrapper)
|
||||||
.toMatchSnapshot();
|
.toMatchSnapshot();
|
||||||
});
|
});
|
||||||
|
|
||||||
test('Click button', () => {
|
test('Click button', async () => {
|
||||||
const wrapper = shallowMount(FsExample);
|
const wrapper = shallowMount(FsExample);
|
||||||
let domButton = wrapper.find('[data-test="fs-example-button"]');
|
let domButton = wrapper.find('[data-test="fs-example-button"]');
|
||||||
domButton.trigger('click');
|
domButton.trigger('click');
|
||||||
|
|
||||||
|
await wrapper.vm.$nextTick();
|
||||||
|
|
||||||
expect(window.nw.require)
|
expect(window.nw.require)
|
||||||
.toHaveBeenCalledWith('fs');
|
.toHaveBeenCalledWith('fs');
|
||||||
|
|
||||||
expect(wrapper.html())
|
expect(wrapper)
|
||||||
.toMatchSnapshot();
|
.toMatchSnapshot();
|
||||||
});
|
});
|
||||||
|
|
||||||
test('Error state', () => {
|
test('Error state', async () => {
|
||||||
window.nw.require.mockImplementation((module) => {
|
window.nw.require.mockImplementation((module) => {
|
||||||
if (module === 'fs') {
|
if (module === 'fs') {
|
||||||
return new Error();
|
return new Error();
|
||||||
@ -32,10 +34,12 @@ describe('FsExample.vue', () => {
|
|||||||
let domButton = wrapper.find('[data-test="fs-example-button"]');
|
let domButton = wrapper.find('[data-test="fs-example-button"]');
|
||||||
domButton.trigger('click');
|
domButton.trigger('click');
|
||||||
|
|
||||||
|
await wrapper.vm.$nextTick();
|
||||||
|
|
||||||
expect(window.nw.require)
|
expect(window.nw.require)
|
||||||
.toHaveBeenCalledWith('fs');
|
.toHaveBeenCalledWith('fs');
|
||||||
|
|
||||||
expect(wrapper.html())
|
expect(wrapper)
|
||||||
.toMatchSnapshot();
|
.toMatchSnapshot();
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
@ -15,23 +15,23 @@ describe('HelloWorld.vue', () => {
|
|||||||
test('Render default contents', () => {
|
test('Render default contents', () => {
|
||||||
const wrapper = mount(HelloWorld);
|
const wrapper = mount(HelloWorld);
|
||||||
|
|
||||||
expect(wrapper.html())
|
expect(wrapper)
|
||||||
.toMatchSnapshot();
|
.toMatchSnapshot();
|
||||||
});
|
});
|
||||||
|
|
||||||
test('Activate dev tools', () => {
|
test('Activate dev tools', async () => {
|
||||||
const wrapper = shallowMount(HelloWorld);
|
const wrapper = shallowMount(HelloWorld);
|
||||||
|
|
||||||
const button = wrapper.find('[data-test="toggleDevTools"]');
|
const button = wrapper.find('[data-test="toggleDevTools"]');
|
||||||
|
|
||||||
button.trigger('click');
|
button.trigger('click');
|
||||||
wrapper.vm.$nextTick();
|
await wrapper.vm.$nextTick();
|
||||||
|
|
||||||
expect(wrapper.find('[data-test="toggleDevTools').html())
|
expect(wrapper.find('[data-test="toggleDevTools').html())
|
||||||
.toMatchSnapshot('hide');
|
.toMatchSnapshot('hide');
|
||||||
|
|
||||||
button.trigger('click');
|
button.trigger('click');
|
||||||
wrapper.vm.$nextTick();
|
await wrapper.vm.$nextTick();
|
||||||
|
|
||||||
expect(wrapper.find('[data-test="toggleDevTools').html())
|
expect(wrapper.find('[data-test="toggleDevTools').html())
|
||||||
.toMatchSnapshot('show');
|
.toMatchSnapshot('show');
|
||||||
|
@ -32,7 +32,7 @@ describe('LinkList.vue', () => {
|
|||||||
propsData: { links: [link] }
|
propsData: { links: [link] }
|
||||||
});
|
});
|
||||||
|
|
||||||
expect(wrapper.html())
|
expect(wrapper)
|
||||||
.toMatchSnapshot();
|
.toMatchSnapshot();
|
||||||
});
|
});
|
||||||
|
|
||||||
|
@ -24,10 +24,10 @@ exports[`HelloWorld.vue Render default contents 1`] = `
|
|||||||
<h3>
|
<h3>
|
||||||
You are using
|
You are using
|
||||||
Vue.js (v2.6.11),
|
Vue.js (v2.6.11),
|
||||||
NW.js (v0.43.6-sdk),
|
NW.js (v0.44.2-sdk),
|
||||||
Node.js (v13.6.0),
|
Node.js (v13.8.0),
|
||||||
and
|
and
|
||||||
Chromium (v79.0.3945.130).
|
Chromium (v80.0.3987.116).
|
||||||
</h3>
|
</h3>
|
||||||
<button>
|
<button>
|
||||||
Show
|
Show
|
||||||
|
@ -27,10 +27,10 @@ global.beforeEach(() => {
|
|||||||
NODE_ENV: 'development'
|
NODE_ENV: 'development'
|
||||||
},
|
},
|
||||||
versions: {
|
versions: {
|
||||||
chromium: '79.0.3945.130',
|
chromium: '80.0.3987.116',
|
||||||
nw: '0.43.6',
|
nw: '0.44.2',
|
||||||
'nw-flavor': 'sdk',
|
'nw-flavor': 'sdk',
|
||||||
node: '13.6.0'
|
node: '13.8.0'
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
window.nw = {
|
window.nw = {
|
||||||
|
Loading…
Reference in New Issue
Block a user