Restart crash service in each spec

This commit is contained in:
Kevin Sawicki 2017-04-19 16:32:43 -07:00 committed by Kevin Sawicki
parent a7a92e1cd3
commit de62f1ea6c
5 changed files with 55 additions and 5 deletions

View file

@ -3,7 +3,7 @@
<script type="text/javascript" charset="utf-8">
const {port} = require('url').parse(window.location.href, true).query
const {crashReporter} = require('electron')
const {crashReporter, ipcRenderer} = require('electron')
crashReporter.start({
productName: 'Zombies',
@ -18,6 +18,10 @@ crashReporter.start({
}
})
if (process.platform === 'win32') {
ipcRenderer.sendSync('crash-service-pid', crashReporter._crashServiceProcess.pid)
}
setImmediate(() => {
if (process.platform === 'darwin') {
crashReporter.setExtraParameter('extra2', 'extra2')

View file

@ -16,6 +16,11 @@ crashReporter.start({
'extra2': 'extra2',
}
});
if (process.platform === 'win32') {
ipcRenderer.sendSync('crash-service-pid', crashReporter._crashServiceProcess.pid)
}
if (!uploadToServer) {
ipcRenderer.sendSync('list-existing-dumps')
}