@dev-blinq/cucumber_client 1.0.1640-dev → 1.0.1642-dev
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.
|
@@ -119,7 +119,21 @@ async function BVTRecorderInit({ envName, projectDir, roomId, TOKEN, socket = nu
|
|
|
119
119
|
// console.error("Browser launch failed", e);
|
|
120
120
|
// }
|
|
121
121
|
|
|
122
|
+
// emit connected event for every 50 ms until connection_ack message is recieved
|
|
123
|
+
let connected = false;
|
|
124
|
+
const interval = setInterval(() => {
|
|
125
|
+
if (connected) {
|
|
126
|
+
clearInterval(interval);
|
|
127
|
+
return;
|
|
128
|
+
}
|
|
129
|
+
socket.emit("BVTRecorder.connected", { roomId, window: "cucumber_client/bvt_recorder" }, roomId);
|
|
130
|
+
}, 50);
|
|
131
|
+
|
|
122
132
|
const promisifiedSocketServer = new PromisifiedSocketServer(socket, {
|
|
133
|
+
"recorderWindow.connectionAck": async (input) => {
|
|
134
|
+
connected = true;
|
|
135
|
+
clearInterval(interval);
|
|
136
|
+
},
|
|
123
137
|
"recorderWindow.openBrowser": async (input) => {
|
|
124
138
|
return recorder
|
|
125
139
|
.openBrowser(input)
|
|
@@ -774,6 +774,7 @@ export class BVTRecorder {
|
|
|
774
774
|
|
|
775
775
|
await this.page.goto(url, {
|
|
776
776
|
waitUntil: "domcontentloaded",
|
|
777
|
+
timeout: this.config.page_timeout ?? 60_000,
|
|
777
778
|
});
|
|
778
779
|
// add listener for frame navigation on current tab
|
|
779
780
|
this._addFrameNavigateListener(this.page);
|