registerConnection(webSocket, socket) {
    if (!this._assertWebSocketIsNotUsed(webSocket)) {
      return;
    }

    const connection = new DetoxConnection({
      sessionManager: this,
      webSocket,
      socket,
    });

    this._connectionsByWs.set(webSocket, connection);
  }
@param {WebSocket} ws
@param {Socket} socket