public void InitializeServer()
		{
			mockServer = new MockServer();
			server = new LocalhostLogServer(mockServer);
			mockClient = new MockClient(mockServer);
			mockClient.Connect("localhost", 1);
			server.Start();
		}
 public void InitializeServer()
 {
     mockServer = new MockServer();
     server     = new LocalhostLogServer(mockServer);
     mockClient = new MockClient(mockServer);
     mockClient.Connect("localhost", 1);
     server.Start();
 }
示例#3
0
 public void StartLogServer()
 {
     server = new LocalhostLogServer(new TcpServer());
     server.Start();
     var ready = false;
     var connection = new OnlineServiceConnection();
     connection.DataReceived += o => ready = true;
     connection.Connect("localhost", LocalhostLogServer.Port);
     connection.Send(new LoginRequest("", "DeltaEngine.Logging.Tests"));
     logger = new NetworkLogger(connection);
     for (int timeoutMs = 1000; timeoutMs > 0 && !ready; timeoutMs -= 10)
         Thread.Sleep(10);
     Assert.IsTrue(ready);
 }
示例#4
0
        public void StartLogServer()
        {
            server = new LocalhostLogServer(new TcpServer());
            server.Start();
            new MockSettings();
            var ready      = false;
            var connection = new OnlineServiceConnection();

            connection.DataReceived += o => ready = true;
            connection.Connect("localhost", LocalhostLogServer.Port);
            connection.Send(new LoginRequest("", "DeltaEngine.Logging.Tests"));
            logger = new NetworkLogger(connection);
            for (int timeoutMs = 1000; timeoutMs > 0 && !ready; timeoutMs -= 10)
            {
                Thread.Sleep(10);
            }
            Assert.IsTrue(ready);
        }