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

Unified Diff: net/quic/quic_crypto_client_stream_test.cc

Issue 754433003: Update from https://crrev.com/305340 (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 6 years, 1 month 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/quic/quic_connection_test.cc ('k') | net/quic/quic_crypto_server_stream.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/quic/quic_crypto_client_stream_test.cc
diff --git a/net/quic/quic_crypto_client_stream_test.cc b/net/quic/quic_crypto_client_stream_test.cc
index 1df2313ada8b76e1fcff041b796251f85bb302af..8e14d775154f4924830d872b1b99747c6f57caa2 100644
--- a/net/quic/quic_crypto_client_stream_test.cc
+++ b/net/quic/quic_crypto_client_stream_test.cc
@@ -34,6 +34,8 @@ class QuicCryptoClientStreamTest : public ::testing::Test {
stream_(new QuicCryptoClientStream(server_id_, session_.get(), nullptr,
&crypto_config_)) {
session_->SetCryptoStream(stream_.get());
+ // Advance the time, because timers do not like uninitialized times.
+ connection_->AdvanceTime(QuicTime::Delta::FromSeconds(1));
}
void CompleteCryptoHandshake() {
@@ -128,8 +130,8 @@ TEST_F(QuicCryptoClientStreamTest, ExpiredServerConfig) {
// Advance time 5 years to ensure that we pass the expiry time of the cached
// server config.
- reinterpret_cast<MockClock*>(const_cast<QuicClock*>(connection_->clock()))
- ->AdvanceTime(QuicTime::Delta::FromSeconds(60 * 60 * 24 * 365 * 5));
+ connection_->AdvanceTime(
+ QuicTime::Delta::FromSeconds(60 * 60 * 24 * 365 * 5));
// Check that a client hello was sent and that CryptoConnect doesn't fail
// with an error.
« no previous file with comments | « net/quic/quic_connection_test.cc ('k') | net/quic/quic_crypto_server_stream.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698