We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent f275319 commit bcd0c31Copy full SHA for bcd0c31
javascript/node/selenium-webdriver/io/exec.js
@@ -134,12 +134,16 @@ function exec(command, opt_options) {
134
proc.unref()
135
process.once('exit', onProcessExit)
136
137
- const result = new Promise((resolve) => {
+ const result = new Promise((resolve, reject) => {
138
proc.once('exit', (code, signal) => {
139
proc = null
140
process.removeListener('exit', onProcessExit)
141
resolve(new Result(code, signal))
142
})
143
+
144
+ proc.once('error', err => {
145
+ reject(err);
146
+ })
147
148
return new Command(result, killCommand)
149
0 commit comments