karma-electron
Advanced tools
Comparing version 7.0.0 to 7.1.0
# karma-electron changelog | ||
7.1.0 - Added `setWindowOpenHandler` to fix `show` not persisting across `window.open`. Fixes #54 | ||
7.0.0 - Added `BrowserWindow#webPreferences.nativeWindowOpen: true` as default for Electron@12 non-Node.js support (more #50) | ||
@@ -3,0 +5,0 @@ |
@@ -95,2 +95,10 @@ // When we run into an uncaught exception, fail hard | ||
var browserWindow = new BrowserWindow(browserWindowOptions); | ||
// Pass along same options to children (e.g. show), https://github.com/twolfson/karma-electron/issues/54 | ||
// https://github.com/electron/electron/blob/v12.1.2/docs/api/window-open.md#native-window-example | ||
browserWindow.webContents.setWindowOpenHandler(function (params) { | ||
return { | ||
action: 'allow', | ||
overrideBrowserWindowOptions: browserWindowOptions | ||
}; | ||
}); | ||
@@ -97,0 +105,0 @@ var loadURLOptions = Object.assign({}, program.loadURLOptions); |
{ | ||
"name": "karma-electron", | ||
"description": "Karma launcher and preprocessor for Electron", | ||
"version": "7.0.0", | ||
"version": "7.1.0", | ||
"homepage": "https://github.com/twolfson/karma-electron", | ||
@@ -6,0 +6,0 @@ "author": { |
@@ -32,2 +32,3 @@ // Load in our dependencies | ||
assert.strictEqual(submodule.loaded, true); | ||
// DEV: While iterating on #54, we noticed Electron@15 changed from `module.parent` to `module.__proto__.parent` | ||
assert.strictEqual(module.hasOwnProperty('parent'), true); | ||
@@ -34,0 +35,0 @@ assert.strictEqual(module.parent, undefined); |
68910
975