@wdio/local-runner 8.0.12 → 8.0.13
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/worker.d.ts +2 -1
- package/build/worker.d.ts.map +1 -1
- package/build/worker.js +8 -15
- package/package.json +3 -3
package/build/worker.d.ts
CHANGED
|
@@ -29,7 +29,8 @@ export default class WorkerInstance extends EventEmitter implements Workers.Work
|
|
|
29
29
|
}>;
|
|
30
30
|
isMultiremote?: boolean;
|
|
31
31
|
isBusy: boolean;
|
|
32
|
-
isReady: boolean
|
|
32
|
+
isReady: Promise<boolean>;
|
|
33
|
+
isReadyResolver: (value: boolean | PromiseLike<boolean>) => void;
|
|
33
34
|
/**
|
|
34
35
|
* assigns paramters to scope of instance
|
|
35
36
|
* @param {object} config parsed configuration object
|
package/build/worker.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"worker.d.ts","sourceRoot":"","sources":["../src/worker.ts"],"names":[],"mappings":";;AAEA,OAAO,KAAK,MAAM,oBAAoB,CAAA;AACtC,OAAO,EAAE,YAAY,EAAE,MAAM,aAAa,CAAA;AAC1C,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAA;AACtD,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,gBAAgB,CAAA;AAC1D,OAAO,KAAK,EAAE,YAAY,EAAE,OAAO,EAAE,OAAO,EAAE,MAAM,aAAa,CAAA;AAkBjE;;;;GAIG;AACH,MAAM,CAAC,OAAO,OAAO,cAAe,SAAQ,YAAa,YAAW,OAAO,CAAC,MAAM;IAC9E,GAAG,EAAE,MAAM,CAAA;IACX,MAAM,EAAE,OAAO,CAAC,UAAU,CAAA;IAC1B,UAAU,EAAE,MAAM,CAAA;IAElB,IAAI,EAAE,YAAY,CAAC,gBAAgB,CAAA;IAEnC,YAAY,EAAE,YAAY,CAAC,gBAAgB,CAAA;IAC3C,KAAK,EAAE,MAAM,EAAE,C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,EAAE,oBAAoB,CAAA;IAC5B,YAAY,CAAC,EAAE,YAAY,CAAA;IAC3B,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,MAAM,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAA;IAE5B,SAAS,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE;QAAE,SAAS,EAAE,MAAM,CAAA;KAAE,CAAC,CAAA;IACjD,aAAa,CAAC,EAAE,OAAO,CAAA;IAEvB,MAAM,UAAQ;IACd,OAAO,EAAE,OAAO,CAAC,OAAO,CAAC,CAAA;IACzB,eAAe,EAAE,CAAC,KAAK,EAAE,OAAO,GAAG,WAAW,CAAC,OAAO,CAAC,KAAK,IAAI,CAAW;IAE3E;;;;;;;;;OASG;gBAEC,MAAM,EAAE,OAAO,CAAC,UAAU,EAC1B,EAAE,GAAG,EAAE,UAAU,EAAE,IAAI,EAAE,KAAK,EAAE,QAAQ,EAAE,OAAO,EAAE,EAAE,OAAO,CAAC,gBAAgB,EAC7E,MAAM,EAAE,oBAAoB,EAC5B,MAAM,EAAE,oBAAoB;IAmBhC;;OAEG;IACH,YAAY;IAuDZ,OAAO,CAAC,cAAc;IAoDtB,OAAO,CAAC,YAAY;IAKpB,OAAO,CAAC,WAAW;IAiBnB;;;;OAIG;IACH,WAAW,CAAE,OAAO,EAAE,MAAM,EAAE,IAAI,EAAE,OAAO,CAAC,iBAAiB,GAAG,IAAI;CAoBvE"}
|
package/build/worker.js
CHANGED
|
@@ -38,7 +38,8 @@ export default class WorkerInstance extends EventEmitter {
|
|
|
38
38
|
instances;
|
|
39
39
|
isMultiremote;
|
|
40
40
|
isBusy = false;
|
|
41
|
-
isReady
|
|
41
|
+
isReady;
|
|
42
|
+
isReadyResolver = () => { };
|
|
42
43
|
/**
|
|
43
44
|
* assigns paramters to scope of instance
|
|
44
45
|
* @param {object} config parsed configuration object
|
|
@@ -61,6 +62,9 @@ export default class WorkerInstance extends EventEmitter {
|
|
|
61
62
|
this.retries = retries;
|
|
62
63
|
this.stdout = stdout;
|
|
63
64
|
this.stderr = stderr;
|
|
65
|
+
this.isReady = new Promise((resolve) => {
|
|
66
|
+
this.isReadyResolver = resolve;
|
|
67
|
+
});
|
|
64
68
|
}
|
|
65
69
|
/**
|
|
66
70
|
* spawns process to kick of wdio-runner
|
|
@@ -122,7 +126,7 @@ export default class WorkerInstance extends EventEmitter {
|
|
|
122
126
|
* mark worker process as ready to receive events
|
|
123
127
|
*/
|
|
124
128
|
if (payload.name === 'ready') {
|
|
125
|
-
this.
|
|
129
|
+
this.isReadyResolver(true);
|
|
126
130
|
}
|
|
127
131
|
/**
|
|
128
132
|
* store sessionId and connection data to worker instance
|
|
@@ -186,19 +190,8 @@ export default class WorkerInstance extends EventEmitter {
|
|
|
186
190
|
this.childProcess = this.startProcess();
|
|
187
191
|
}
|
|
188
192
|
const cmd = { cid, command, configFile, args, caps: capabilities, specs, retries };
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
this.on('message', (payload) => {
|
|
192
|
-
if (payload.name === 'ready') {
|
|
193
|
-
log.debug(`Worker with cid "${cid}" now ready, sending ${command}`);
|
|
194
|
-
this.childProcess.send(cmd);
|
|
195
|
-
}
|
|
196
|
-
});
|
|
197
|
-
}
|
|
198
|
-
else {
|
|
199
|
-
log.debug(`Send command ${command} to worker with cid "${cid}"`);
|
|
200
|
-
this.childProcess.send(cmd);
|
|
201
|
-
}
|
|
193
|
+
log.debug(`Send command ${command} to worker with cid "${cid}"`);
|
|
194
|
+
this.isReady.then(() => this.childProcess.send(cmd));
|
|
202
195
|
this.isBusy = true;
|
|
203
196
|
}
|
|
204
197
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@wdio/local-runner",
|
|
3
|
-
"version": "8.0.
|
|
3
|
+
"version": "8.0.13",
|
|
4
4
|
"description": "A WebdriverIO runner to run tests locally",
|
|
5
5
|
"author": "Christian Bromann <mail@bromann.dev>",
|
|
6
6
|
"homepage": "https://github.com/webdriverio/webdriverio/tree/main/packages/wdio-local-runner",
|
|
@@ -30,7 +30,7 @@
|
|
|
30
30
|
"@types/stream-buffers": "^3.0.4",
|
|
31
31
|
"@wdio/logger": "8.0.0",
|
|
32
32
|
"@wdio/repl": "8.0.0",
|
|
33
|
-
"@wdio/runner": "8.0.
|
|
33
|
+
"@wdio/runner": "8.0.13",
|
|
34
34
|
"@wdio/types": "8.0.11",
|
|
35
35
|
"async-exit-hook": "^2.0.1",
|
|
36
36
|
"split2": "^4.1.0",
|
|
@@ -39,5 +39,5 @@
|
|
|
39
39
|
"publishConfig": {
|
|
40
40
|
"access": "public"
|
|
41
41
|
},
|
|
42
|
-
"gitHead": "
|
|
42
|
+
"gitHead": "912db21d2cd4552a02b776ba74cae05440b076de"
|
|
43
43
|
}
|