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

Unified Diff: components/data_reduction_proxy/core/common/data_reduction_proxy_event_store_unittest.cc

Issue 1109473003: Get rid of TestNetLog::CapturedEntry[List] typedefs. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 8 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 | « no previous file | net/cert/multi_log_ct_verifier_unittest.cc » ('j') | net/log/net_log_unittest.h » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/data_reduction_proxy/core/common/data_reduction_proxy_event_store_unittest.cc
diff --git a/components/data_reduction_proxy/core/common/data_reduction_proxy_event_store_unittest.cc b/components/data_reduction_proxy/core/common/data_reduction_proxy_event_store_unittest.cc
index 05c996bb2582dfd09c948435a82c7d9dc3c6124d..9f512d428f8aba08965ec0d332ce807520e37412 100644
--- a/components/data_reduction_proxy/core/common/data_reduction_proxy_event_store_unittest.cc
+++ b/components/data_reduction_proxy/core/common/data_reduction_proxy_event_store_unittest.cc
@@ -11,6 +11,7 @@
#include "components/data_reduction_proxy/core/common/data_reduction_proxy_event_creator.h"
#include "components/data_reduction_proxy/core/common/data_reduction_proxy_params_test_utils.h"
#include "net/http/http_status_code.h"
+#include "net/log/captured_net_log_entry.h"
#include "net/log/net_log.h"
#include "net/log/test_net_log.h"
#include "testing/gtest/include/gtest/gtest.h"
@@ -30,8 +31,8 @@ class DataReductionProxyEventStoreTest : public testing::Test {
new DataReductionProxyEventCreator(event_store_.get()));
}
- net::TestNetLog::CapturedEntry GetSingleEntry() const {
- net::TestNetLog::CapturedEntryList entries;
+ net::CapturedNetLogEntry GetSingleEntry() const {
+ net::CapturedNetLogEntry::List entries;
net_log_->GetEntries(&entries);
EXPECT_EQ(1u, entries.size());
return entries[0];
@@ -63,7 +64,7 @@ TEST_F(DataReductionProxyEventStoreTest, TestAddProxyEnabledEvent) {
TestDataReductionProxyParams::DefaultFallbackOrigin(),
TestDataReductionProxyParams::DefaultSSLOrigin());
EXPECT_EQ(1u, event_store()->stored_events_.size());
- net::TestNetLog::CapturedEntry entry = GetSingleEntry();
+ net::CapturedNetLogEntry entry = GetSingleEntry();
EXPECT_EQ(net::NetLog::TYPE_DATA_REDUCTION_PROXY_ENABLED,
entry.type);
}
@@ -72,7 +73,7 @@ TEST_F(DataReductionProxyEventStoreTest, TestAddProxyDisabledEvent) {
EXPECT_EQ(0u, event_store()->stored_events_.size());
event_creator()->AddProxyDisabledEvent(net_log());
EXPECT_EQ(1u, event_store()->stored_events_.size());
- net::TestNetLog::CapturedEntry entry = GetSingleEntry();
+ net::CapturedNetLogEntry entry = GetSingleEntry();
EXPECT_EQ(net::NetLog::TYPE_DATA_REDUCTION_PROXY_ENABLED,
entry.type);
}
@@ -83,7 +84,7 @@ TEST_F(DataReductionProxyEventStoreTest, TestAddBypassActionEvent) {
event_creator()->AddBypassActionEvent(bound_net_log(), "bypass", GURL(),
base::TimeDelta::FromMinutes(1));
EXPECT_EQ(1u, event_store()->stored_events_.size());
- net::TestNetLog::CapturedEntry entry = GetSingleEntry();
+ net::CapturedNetLogEntry entry = GetSingleEntry();
EXPECT_EQ(net::NetLog::TYPE_DATA_REDUCTION_PROXY_BYPASS_REQUESTED,
entry.type);
EXPECT_NE(nullptr, event_store()->last_bypass_event_.get());
@@ -96,7 +97,7 @@ TEST_F(DataReductionProxyEventStoreTest, TestAddBypassTypeEvent) {
GURL(), base::TimeDelta::FromMinutes(1));
EXPECT_EQ(1u, event_store()->stored_events_.size());
EXPECT_EQ(1u, net_log()->GetSize());
- net::TestNetLog::CapturedEntry entry = GetSingleEntry();
+ net::CapturedNetLogEntry entry = GetSingleEntry();
EXPECT_EQ(net::NetLog::TYPE_DATA_REDUCTION_PROXY_BYPASS_REQUESTED,
entry.type);
EXPECT_NE(nullptr, event_store()->last_bypass_event_.get());
@@ -109,7 +110,7 @@ TEST_F(DataReductionProxyEventStoreTest, TestBeginSecureProxyCheck) {
event_creator()->BeginSecureProxyCheck(bound_net_log(), GURL());
EXPECT_EQ(1u, event_store()->stored_events_.size());
EXPECT_EQ(1u, net_log()->GetSize());
- net::TestNetLog::CapturedEntry entry = GetSingleEntry();
+ net::CapturedNetLogEntry entry = GetSingleEntry();
EXPECT_EQ(net::NetLog::TYPE_DATA_REDUCTION_PROXY_CANARY_REQUEST,
entry.type);
EXPECT_EQ(DataReductionProxyEventStorageDelegate::CHECK_PENDING,
@@ -123,7 +124,7 @@ TEST_F(DataReductionProxyEventStoreTest, TestEndSecureProxyCheck) {
event_creator()->EndSecureProxyCheck(bound_net_log(), 0, net::HTTP_OK, true);
EXPECT_EQ(1u, event_store()->stored_events_.size());
EXPECT_EQ(1u, net_log()->GetSize());
- net::TestNetLog::CapturedEntry entry = GetSingleEntry();
+ net::CapturedNetLogEntry entry = GetSingleEntry();
EXPECT_EQ(net::NetLog::TYPE_DATA_REDUCTION_PROXY_CANARY_REQUEST,
entry.type);
EXPECT_EQ(DataReductionProxyEventStorageDelegate::CHECK_SUCCESS,
« no previous file with comments | « no previous file | net/cert/multi_log_ct_verifier_unittest.cc » ('j') | net/log/net_log_unittest.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698