[MM-50011] Disable popping the dialog box for uncaught exceptions (#2519)
This commit is contained in:
@@ -46,8 +46,8 @@
|
||||
"test:e2e:build": "webpack-cli --config webpack.config.test.js",
|
||||
"test:e2e:run": "electron-mocha -r @babel/register --reporter mochawesome dist/tests/e2e_bundle.js",
|
||||
"test:e2e:send-report": "node ./e2e/save_report.js",
|
||||
"test:unit": "jest",
|
||||
"test:unit-ci": "jest --runInBand",
|
||||
"test:unit": "cross-env NODE_ENV=jest jest",
|
||||
"test:unit-ci": "cross-env NODE_ENV=jest jest --runInBand",
|
||||
"test:coverage": "jest --coverage",
|
||||
"package:all": "cross-env NODE_ENV=production npm-run-all package:windows package:windows-nsis package:mac package:mac-with-universal package:linux",
|
||||
"package:windows": "npm-run-all build-prod && electron-builder --win zip --x64 --ia32 --arm64 --publish=never",
|
||||
|
@@ -68,6 +68,10 @@ export class CriticalErrorHandler {
|
||||
const report = createErrorReport(err);
|
||||
fs.writeFileSync(file, report.replace(new RegExp('\\n', 'g'), os.EOL));
|
||||
|
||||
if (process.env.NODE_ENV === 'test') {
|
||||
return;
|
||||
}
|
||||
|
||||
if (app.isReady()) {
|
||||
const buttons = [
|
||||
localizeMessage('main.CriticalErrorHandler.uncaughtException.button.showDetails', 'Show Details'),
|
||||
|
Reference in New Issue
Block a user