mirror of
https://github.com/clusterio/clusterio.git
synced 2026-11-13 23:14:53 +09:00
Replace socket.io with plain WebSocket
Replace socket.io with plain WebSocket using the ws library as it doesn't really provide any useful tools over plain WebSocket when it comes to implementing reliable communication that works across reconnects. The widespread browser support for WebSocket also means it has little value to add for the web interface over WebSocket.
This commit is contained in:
1 parent
808bd6b453
commit
677512512e
12 files changed
+139
-149
No files matched your search
+4
-4
@@ -63,13 +63,13 @@ describe('Master testing', function() {
|
||||
}
|
||||
});
|
||||
|
||||
describe("class SocketIOServerConnector", function() {
|
||||
let testConnector = new master._SocketIOServerConnector(new mock.MockSocket());
|
||||
describe("class WebSocketServerConnector", function() {
|
||||
let testConnector = new master._WebSocketServerConnector(new mock.MockSocket());
|
||||
describe(".disconnect()", function() {
|
||||
it("should call disconnect on the socket", function() {
|
||||
testConnector._socket.disconnectCalled = false;
|
||||
testConnector._socket.terminateCalled = false;
|
||||
testConnector.disconnect();
|
||||
assert(testConnector._socket.disconnectCalled, "Disconnect was not called");
|
||||
assert(testConnector._socket.terminateCalled, "Terminate was not called");
|
||||
});
|
||||
});
|
||||
});
|
||||
|
||||
Reference in new issue
Block a user