Skip to content

Commit 15f4501

Browse files
committed
Report firefox failure exit codes
1 parent f21e207 commit 15f4501

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/interceptors/fresh-firefox.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -133,12 +133,12 @@ export class FreshFirefox implements Interceptor {
133133
let certInstalled: Promise<void> | true = certCheckServer.waitForSuccess().catch(reportError);
134134

135135
certInstallBrowser = await this.startFirefox(certCheckServer);
136-
certInstallBrowser.process.once('close', () => {
136+
certInstallBrowser.process.once('close', (exitCode) => {
137137
certCheckServer.stop();
138138
certInstallBrowser = undefined;
139139

140140
if (certInstalled !== true) {
141-
reportError('Firefox certificate setup failed');
141+
reportError(`Firefox certificate profile setup failed with code ${exitCode}`);
142142
deleteFolder(this.firefoxProfilePath).catch(console.warn);
143143
}
144144
});
@@ -199,11 +199,11 @@ export class FreshFirefox implements Interceptor {
199199
}).catch(reportError);
200200

201201
browsers[proxyPort] = browser;
202-
browser.process.once('close', () => {
202+
browser.process.once('close', (exitCode) => {
203203
certCheckServer.stop();
204204
delete browsers[proxyPort];
205205
if (!success) {
206-
reportError('Firefox certificate check failed');
206+
reportError(`Firefox certificate check failed with code ${exitCode}`);
207207
deleteFolder(this.firefoxProfilePath).catch(console.warn);
208208
}
209209
});

0 commit comments

Comments
 (0)