Skip to content

Commit

Permalink
Fixing unit tests
Browse files Browse the repository at this point in the history
  • Loading branch information
chronoxor committed May 18, 2021
1 parent bbbef5a commit 0cd15c4
Showing 1 changed file with 8 additions and 7 deletions.
15 changes: 8 additions & 7 deletions tests/WssTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ public void WssServerTest()
Assert.True(client.BytesReceived > 0);
Assert.True(!client.Errors);
}
/*

[Fact(DisplayName = "WebSocket secure server multicast test")]
public void WssServerMulticastTest()
{
Expand Down Expand Up @@ -174,7 +174,7 @@ public void WssServerMulticastTest()
// Wait for all data processed...
while (client1.Received != 4)
Thread.Yield();
/*
// Create and connect Echo client
var client2 = new EchoWssClient(clientContext, address, port);
Assert.True(client2.ConnectAsync());
Expand All @@ -200,12 +200,12 @@ public void WssServerMulticastTest()
// Wait for all data processed...
while ((client1.Received != 12) || (client2.Received != 8) || (client3.Received != 4))
Thread.Yield();
*/
// Disconnect the Echo client
Assert.True(client1.CloseAsync(1000));
while (client1.IsWsConnected || (server.Clients != 2))
Thread.Yield();
/*
// Multicast some data to all clients
server.MulticastText("test");
Expand All @@ -229,7 +229,7 @@ public void WssServerMulticastTest()
Assert.True(client3.CloseAsync(1000));
while (client3.IsWsConnected || (server.Clients != 0))
Thread.Yield();
*/
// Stop the Echo server
Assert.True(server.Stop());
while (server.IsStarted)
Expand All @@ -243,7 +243,7 @@ public void WssServerMulticastTest()
Assert.True(server.BytesSent > 0);
Assert.True(server.BytesReceived > 0);
Assert.True(!server.Errors);
/*
// Check the Echo client state
Assert.True(client1.BytesSent > 0);
Assert.True(client2.BytesSent > 0);
Expand All @@ -254,8 +254,9 @@ public void WssServerMulticastTest()
Assert.True(!client1.Errors);
Assert.True(!client2.Errors);
Assert.True(!client3.Errors);
*/
}
*/

[Fact(DisplayName = "WebSocket secure server random test")]
public void WssServerRandomTest()
{
Expand Down

0 comments on commit 0cd15c4

Please sign in to comment.