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

Unified Diff: net/quic/chromium/properties_based_quic_server_info_test.cc

Issue 2820573004: Remove the code to store and load QUIC server configs in the disk cache. (Closed)
Patch Set: Fix Created 3 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
Index: net/quic/chromium/properties_based_quic_server_info_test.cc
diff --git a/net/quic/chromium/properties_based_quic_server_info_test.cc b/net/quic/chromium/properties_based_quic_server_info_test.cc
index aba7c635f481f267b46d54142a4e3e7ceca5b5e3..c4cc0638576f0f9fcd455769b462f9a0d908856d 100644
--- a/net/quic/chromium/properties_based_quic_server_info_test.cc
+++ b/net/quic/chromium/properties_based_quic_server_info_test.cc
@@ -34,8 +34,6 @@ class PropertiesBasedQuicServerInfoTest : public ::testing::Test {
// Initialize |server_info_| object and persist it.
void InitializeAndPersist() {
- server_info_.Start();
- EXPECT_TRUE(server_info_.IsDataReady());
QuicServerInfo::State* state = server_info_.mutable_state();
EXPECT_TRUE(state->certs.empty());
@@ -45,11 +43,7 @@ class PropertiesBasedQuicServerInfoTest : public ::testing::Test {
state->cert_sct = kCertSCTA;
state->chlo_hash = kChloHashA;
state->certs.push_back(kCertA);
- EXPECT_TRUE(server_info_.IsReadyToPersist());
server_info_.Persist();
- EXPECT_TRUE(server_info_.IsReadyToPersist());
- EXPECT_TRUE(server_info_.IsDataReady());
- server_info_.OnExternalCacheHit();
}
// Verify the data that is persisted in InitializeAndPersist().
@@ -75,10 +69,7 @@ TEST_F(PropertiesBasedQuicServerInfoTest, Update) {
// Read the persisted data and verify we have read the data correctly.
PropertiesBasedQuicServerInfo server_info1(server_id_,
&http_server_properties_);
- server_info1.Start();
- EXPECT_THAT(server_info1.WaitForDataReady(callback_),
- IsOk()); // Read the data.
- EXPECT_TRUE(server_info1.IsDataReady());
+ EXPECT_TRUE(server_info1.Load());
// Verify the data.
const QuicServerInfo::State& state1 = server_info1.state();
@@ -88,16 +79,12 @@ TEST_F(PropertiesBasedQuicServerInfoTest, Update) {
// Update the data, by adding another cert.
QuicServerInfo::State* state2 = server_info1.mutable_state();
state2->certs.push_back(kCertB);
- EXPECT_TRUE(server_info_.IsReadyToPersist());
server_info1.Persist();
// Read the persisted data and verify we have read the data correctly.
PropertiesBasedQuicServerInfo server_info2(server_id_,
&http_server_properties_);
- server_info2.Start();
- EXPECT_THAT(server_info2.WaitForDataReady(callback_),
- IsOk()); // Read the data.
- EXPECT_TRUE(server_info1.IsDataReady());
+ EXPECT_TRUE(server_info2.Load());
// Verify updated data.
const QuicServerInfo::State& state3 = server_info2.state();
« no previous file with comments | « net/quic/chromium/properties_based_quic_server_info.cc ('k') | net/quic/chromium/quic_chromium_client_session.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698