Skip to content

Commit 0af0ad4

Browse files
committed
fix
1 parent d43355d commit 0af0ad4

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

src/SignalR/clients/ts/signalr/tests/HttpConnection.test.ts

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -230,7 +230,7 @@ describe("HttpConnection", () => {
230230
const connection = new HttpConnection("http://tempuri.org", options);
231231
await expect(connection.start(TransferFormat.Text))
232232
.rejects
233-
.toThrow("Unable to connect to the server with any of the available transports. WebSockets failed: Error: WebSocket failed to connect. " +
233+
.toThrow("Unable to connect to the server with any of the available transports. Error: WebSockets failed: Error: WebSocket failed to connect. " +
234234
"The connection could not be found on the server, either the endpoint may not be a SignalR endpoint, the connection ID is not present on the server, " +
235235
"or there is a proxy blocking WebSockets. If you have multiple servers check that sticky sessions are enabled. ServerSentEvents failed: Error: 'ServerSentEvents' is disabled by the client. LongPolling failed: Error: 'LongPolling' is disabled by the client.");
236236

@@ -239,7 +239,7 @@ describe("HttpConnection", () => {
239239
/* eslint-disable max-len */
240240
"Failed to start the transport 'WebSockets': Error: WebSocket failed to connect. The connection could not be found on the server, " +
241241
"either the endpoint may not be a SignalR endpoint, the connection ID is not present on the server, or there is a proxy blocking WebSockets. If you have multiple servers check that sticky sessions are enabled.",
242-
"Failed to start the connection: Error: Unable to connect to the server with any of the available transports. WebSockets failed: " +
242+
"Failed to start the connection: Error: Unable to connect to the server with any of the available transports. Error: WebSockets failed: " +
243243
"Error: WebSocket failed to connect. The connection could not be found on the server, either the endpoint may not be a SignalR endpoint, the connection ID is not present on the server, or there is a proxy blocking WebSockets. If you have multiple servers check that sticky sessions are enabled. ServerSentEvents failed: Error: 'ServerSentEvents' is disabled by the client. LongPolling failed: Error: 'LongPolling' is disabled by the client.");
244244
/* eslint-enable max-len */
245245
});
@@ -266,13 +266,13 @@ describe("HttpConnection", () => {
266266
const connection = new HttpConnection("http://tempuri.org", options);
267267
await expect(connection.start(TransferFormat.Text))
268268
.rejects
269-
.toThrow("Unable to connect to the server with any of the available transports. WebSockets failed: Error: Don't allow Websockets. ServerSentEvents failed: Error: Don't allow ServerSentEvents. LongPolling failed: Error: 'LongPolling' is disabled by the client.");
269+
.toThrow("Unable to connect to the server with any of the available transports. Error: WebSockets failed: Error: Don't allow Websockets. Error: ServerSentEvents failed: Error: Don't allow ServerSentEvents. LongPolling failed: Error: 'LongPolling' is disabled by the client.");
270270

271271
expect(negotiateCount).toEqual(2);
272272
},
273273
"Failed to start the transport 'WebSockets': Error: Don't allow Websockets.",
274274
"Failed to start the transport 'ServerSentEvents': Error: Don't allow ServerSentEvents.",
275-
"Failed to start the connection: Error: Unable to connect to the server with any of the available transports. WebSockets failed: Error: Don't allow Websockets. ServerSentEvents failed: Error: Don't allow ServerSentEvents. LongPolling failed: Error: 'LongPolling' is disabled by the client.");
275+
"Failed to start the connection: Error: Unable to connect to the server with any of the available transports. Error: WebSockets failed: Error: Don't allow Websockets. Error: ServerSentEvents failed: Error: Don't allow ServerSentEvents. LongPolling failed: Error: 'LongPolling' is disabled by the client.");
276276
});
277277

278278
it("failed re-negotiate fails start", async () => {
@@ -1331,12 +1331,12 @@ describe("HttpConnection", () => {
13311331

13321332
await expect(connection.start(TransferFormat.Text))
13331333
.rejects
1334-
.toEqual(new Error("Unable to connect to the server with any of the available transports. ServerSentEvents failed: Error: EventSource constructor called."));
1334+
.toEqual(new Error("Unable to connect to the server with any of the available transports. Error: ServerSentEvents failed: Error: EventSource constructor called."));
13351335

13361336
expect(eventSourceConstructorCalled).toEqual(true);
13371337
},
13381338
"Failed to start the transport 'ServerSentEvents': Error: EventSource constructor called.",
1339-
"Failed to start the connection: Error: Unable to connect to the server with any of the available transports. ServerSentEvents failed: Error: EventSource constructor called.");
1339+
"Failed to start the connection: Error: Unable to connect to the server with any of the available transports. Error: ServerSentEvents failed: Error: EventSource constructor called.");
13401340
});
13411341

13421342
it("uses WebSocket constructor from options if provided", async () => {

0 commit comments

Comments
 (0)