mirror of
https://github.com/MichMich/MagicMirror.git
synced 2025-06-28 17:44:52 -04:00
workaround for dev_console test using getWindowCount
This commit is contained in:
parent
3418c9b50f
commit
cfc0bcd5ad
3 changed files with 23 additions and 19 deletions
|
@ -63,6 +63,11 @@ function createWindow() {
|
|||
|
||||
// Open the DevTools if run with "npm start dev"
|
||||
if (process.argv.includes("dev")) {
|
||||
if (process.env.JEST_WORKER_ID !== undefined) {
|
||||
// if we are running with jest
|
||||
var devtools = new BrowserWindow(electronOptions);
|
||||
mainWindow.webContents.setDevToolsWebContents(devtools.webContents);
|
||||
}
|
||||
mainWindow.webContents.openDevTools();
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue