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

Unified Diff: net/nqe/network_quality_estimator_unittest.cc

Issue 2663963002: Add effective connection type to throughput mapping (Closed)
Patch Set: Created 3 years, 11 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/nqe/network_quality_estimator_params.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/nqe/network_quality_estimator_unittest.cc
diff --git a/net/nqe/network_quality_estimator_unittest.cc b/net/nqe/network_quality_estimator_unittest.cc
index d4a6b5cab7081e8dfe2160b5d4ccaa0187f6f90f..e4ecc026a5074665243190fa34a5231fcaec85f9 100644
--- a/net/nqe/network_quality_estimator_unittest.cc
+++ b/net/nqe/network_quality_estimator_unittest.cc
@@ -2642,13 +2642,12 @@ TEST(NetworkQualityEstimatorTest, OnPrefsRead) {
EXPECT_EQ(base::TimeDelta::FromMilliseconds(1500),
rtt_observer.last_rtt(
NETWORK_QUALITY_OBSERVATION_SOURCE_TRANSPORT_CACHED_ESTIMATE));
- EXPECT_EQ(0u, throughput_observer.observations().size());
+ EXPECT_EQ(1u, throughput_observer.observations().size());
EXPECT_EQ(base::TimeDelta::FromMilliseconds(1800),
rtt_throughput_observer.http_rtt());
EXPECT_EQ(base::TimeDelta::FromMilliseconds(1500),
rtt_throughput_observer.transport_rtt());
- EXPECT_EQ(nqe::internal::kInvalidThroughput,
- rtt_throughput_observer.downstream_throughput_kbps());
+ EXPECT_EQ(75, rtt_throughput_observer.downstream_throughput_kbps());
EXPECT_LE(
1u,
effective_connection_type_observer.effective_connection_types().size());
@@ -2670,13 +2669,12 @@ TEST(NetworkQualityEstimatorTest, OnPrefsRead) {
EXPECT_EQ(base::TimeDelta::FromMilliseconds(3000),
rtt_observer.last_rtt(
NETWORK_QUALITY_OBSERVATION_SOURCE_TRANSPORT_CACHED_ESTIMATE));
- EXPECT_EQ(0u, throughput_observer.observations().size());
+ EXPECT_EQ(2U, throughput_observer.observations().size());
EXPECT_EQ(base::TimeDelta::FromMilliseconds(3600),
rtt_throughput_observer.http_rtt());
EXPECT_EQ(base::TimeDelta::FromMilliseconds(3000),
rtt_throughput_observer.transport_rtt());
- EXPECT_EQ(nqe::internal::kInvalidThroughput,
- rtt_throughput_observer.downstream_throughput_kbps());
+ EXPECT_EQ(40, rtt_throughput_observer.downstream_throughput_kbps());
EXPECT_LE(
2u,
effective_connection_type_observer.effective_connection_types().size());
« no previous file with comments | « net/nqe/network_quality_estimator_params.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698