Index: net/quic/quic_server_test.cc |
diff --git a/net/tools/quic/quic_server_test.cc b/net/quic/quic_server_test.cc |
similarity index 72% |
copy from net/tools/quic/quic_server_test.cc |
copy to net/quic/quic_server_test.cc |
index e2d7c4f3288f363689eb9a47a72b32ec3cd38b5f..9a6e79806b138c3e10516669203dd903f0771ca5 100644 |
--- a/net/tools/quic/quic_server_test.cc |
+++ b/net/quic/quic_server_test.cc |
@@ -2,27 +2,28 @@ |
// Use of this source code is governed by a BSD-style license that can be |
// found in the LICENSE file. |
-#include "net/tools/quic/quic_server.h" |
+#include "net/quic/quic_server.h" |
#include "net/quic/crypto/quic_random.h" |
#include "net/quic/quic_utils.h" |
-#include "net/tools/quic/test_tools/mock_quic_dispatcher.h" |
+#include "net/quic/test_tools/mock_quic_dispatcher.h" |
+#include "net/quic/test_tools/quic_test_utils.h" |
#include "testing/gtest/include/gtest/gtest.h" |
using ::testing::_; |
namespace net { |
-namespace tools { |
namespace test { |
namespace { |
-class QuicServerDispatchPacketTest : public ::testing::Test { |
+// TODO(dmz) Remove "Chrome" part of name once tools/quic is deleted. |
wtc
2014/06/23 23:12:16
Nit: don't omit "net" in the path name. Say "net/t
dmziegler
2014/06/24 00:08:53
Done.
|
+class QuicChromeServerDispatchPacketTest : public ::testing::Test { |
public: |
- QuicServerDispatchPacketTest() |
+ QuicChromeServerDispatchPacketTest() |
: crypto_config_("blah", QuicRandom::GetInstance()), |
- dispatcher_(config_, crypto_config_, &eps_) { |
- dispatcher_.Initialize(1234); |
+ dispatcher_(config_, crypto_config_, &helper_) { |
+ dispatcher_.Initialize(NULL); |
} |
void DispatchPacket(const QuicEncryptedPacket& packet) { |
@@ -33,11 +34,11 @@ class QuicServerDispatchPacketTest : public ::testing::Test { |
protected: |
QuicConfig config_; |
QuicCryptoServerConfig crypto_config_; |
- EpollServer eps_; |
+ MockHelper helper_; |
MockQuicDispatcher dispatcher_; |
}; |
-TEST_F(QuicServerDispatchPacketTest, DispatchPacket) { |
+TEST_F(QuicChromeServerDispatchPacketTest, DispatchPacket) { |
unsigned char valid_packet[] = { |
// public flags (8 byte connection_id) |
0x3C, |
@@ -58,5 +59,4 @@ TEST_F(QuicServerDispatchPacketTest, DispatchPacket) { |
} // namespace |
} // namespace test |
-} // namespace tools |
} // namespace net |