Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(256)

Unified Diff: net/socket/tcp_client_socket_unittest.cc

Issue 848006: Generalize the net module's LoadLog facility from a passive container, to an event stream (NetLog). (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Split up RequestTracker into ConnectJobTracker+RequestTracker+RequestTrackerBase, address comments Created 10 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « net/socket/tcp_client_socket_pool_unittest.cc ('k') | net/socket/tcp_client_socket_win.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/socket/tcp_client_socket_unittest.cc
===================================================================
--- net/socket/tcp_client_socket_unittest.cc (revision 41560)
+++ net/socket/tcp_client_socket_unittest.cc (working copy)
@@ -9,8 +9,8 @@
#include "net/base/host_resolver.h"
#include "net/base/io_buffer.h"
#include "net/base/listen_socket.h"
-#include "net/base/load_log.h"
-#include "net/base/load_log_unittest.h"
+#include "net/base/net_log.h"
+#include "net/base/net_log_unittest.h"
#include "net/base/net_errors.h"
#include "net/base/test_completion_callback.h"
#include "net/base/winsock_init.h"
@@ -99,14 +99,14 @@
TestCompletionCallback callback;
EXPECT_FALSE(sock_->IsConnected());
- scoped_refptr<LoadLog> log(new LoadLog(LoadLog::kUnbounded));
- int rv = sock_->Connect(&callback, log);
+ CapturingBoundNetLog log(CapturingNetLog::kUnbounded);
+ int rv = sock_->Connect(&callback, log.bound());
EXPECT_TRUE(net::LogContainsBeginEvent(
- *log, 0, net::LoadLog::TYPE_TCP_CONNECT));
+ log.entries(), 0, net::NetLog::TYPE_TCP_CONNECT));
if (rv != OK) {
ASSERT_EQ(rv, ERR_IO_PENDING);
EXPECT_FALSE(net::LogContainsEndEvent(
- *log, -1, net::LoadLog::TYPE_TCP_CONNECT));
+ log.entries(), -1, net::NetLog::TYPE_TCP_CONNECT));
rv = callback.WaitForResult();
EXPECT_EQ(rv, OK);
@@ -114,7 +114,7 @@
EXPECT_TRUE(sock_->IsConnected());
EXPECT_TRUE(net::LogContainsEndEvent(
- *log, -1, net::LoadLog::TYPE_TCP_CONNECT));
+ log.entries(), -1, net::NetLog::TYPE_TCP_CONNECT));
sock_->Disconnect();
EXPECT_FALSE(sock_->IsConnected());
« no previous file with comments | « net/socket/tcp_client_socket_pool_unittest.cc ('k') | net/socket/tcp_client_socket_win.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698