OLD | NEW |
1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 // Tests TelnetServer. | 5 // Tests TelnetServer. |
6 | 6 |
7 #include "base/platform_test.h" | |
8 #include "net/base/listen_socket_unittest.h" | 7 #include "net/base/listen_socket_unittest.h" |
9 #include "net/base/telnet_server.h" | 8 #include "net/base/telnet_server.h" |
| 9 #include "testing/platform_test.h" |
10 | 10 |
11 static const char* kCRLF = "\r\n"; | 11 static const char* kCRLF = "\r\n"; |
12 | 12 |
13 class TelnetServerTester : public ListenSocketTester { | 13 class TelnetServerTester : public ListenSocketTester { |
14 public: | 14 public: |
15 virtual ListenSocket* DoListen() { | 15 virtual ListenSocket* DoListen() { |
16 return TelnetServer::Listen("127.0.0.1", kTestPort, this); | 16 return TelnetServer::Listen("127.0.0.1", kTestPort, this); |
17 } | 17 } |
18 | 18 |
19 virtual void SetUp() { | 19 virtual void SetUp() { |
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
61 } | 61 } |
62 | 62 |
63 TEST_F(TelnetServerTest, ClientSendLong) { | 63 TEST_F(TelnetServerTest, ClientSendLong) { |
64 tester_->TestClientSendLong(); | 64 tester_->TestClientSendLong(); |
65 } | 65 } |
66 | 66 |
67 TEST_F(TelnetServerTest, ServerSend) { | 67 TEST_F(TelnetServerTest, ServerSend) { |
68 tester_->TestServerSend(); | 68 tester_->TestServerSend(); |
69 } | 69 } |
70 | 70 |
OLD | NEW |