Skip to content
This repository has been archived by the owner on Oct 10, 2024. It is now read-only.

Commit

Permalink
Bubble up TCP connection errors (#1)
Browse files Browse the repository at this point in the history
  • Loading branch information
flotwig authored Feb 7, 2020
1 parent b861274 commit 2cddf7d
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion lib/marionette/drivers/tcp.js
Original file line number Diff line number Diff line change
Expand Up @@ -73,8 +73,13 @@ Tcp.prototype._connect = function connect(callbackpromises) {
tries: this.tries
};
retrySocket.waitForSocket(options, function(err, socket) {
debug('got socket starting command stream');
debug('got socket starting command stream %o', { err: err });

if (callbackpromises){
if (err) {
return callbackpromises(err)
}

this.callbackpromises = callbackpromises;
}
this.socket = socket;
Expand Down

0 comments on commit 2cddf7d

Please sign in to comment.