Index: net/nqe/network_quality_estimator.h |
diff --git a/net/nqe/network_quality_estimator.h b/net/nqe/network_quality_estimator.h |
index d11b4841628cec93f6b83ffb75f15e6cd50f8035..7d2746ce1ee3894a4f55fd2480a2e6994af10671 100644 |
--- a/net/nqe/network_quality_estimator.h |
+++ b/net/nqe/network_quality_estimator.h |
@@ -256,6 +256,17 @@ class NET_EXPORT_PRIVATE NetworkQualityEstimator |
SocketPerformanceWatcherFactory* GetSocketPerformanceWatcherFactory(); |
+ // |use_local_host_requests_for_tests| should only be true when testing |
+ // against local HTTP server and allows the requests to local host to be |
+ // used for network quality estimation. |
+ void SetUseLocalHostRequestsForTesting( |
+ bool use_local_host_requests_for_tests); |
+ |
+ // |use_smaller_responses_for_tests| should only be true when testing. |
+ // Allows the responses smaller than |kMinTransferSizeInBits| to be used for |
+ // network quality estimation. |
+ void SetUseSmallResponsesForTesting(bool use_small_responses); |
+ |
protected: |
// NetworkID is used to uniquely identify a network. |
// For the purpose of network quality estimation and caching, a network is |
@@ -490,12 +501,12 @@ class NET_EXPORT_PRIVATE NetworkQualityEstimator |
// Determines if the requests to local host can be used in estimating the |
// network quality. Set to true only for tests. |
- const bool use_localhost_requests_; |
+ bool use_localhost_requests_; |
// Determines if the responses smaller than |kMinTransferSizeInBytes| |
// or shorter than |kMinTransferSizeInBytes| can be used in estimating the |
// network quality. Set to true only for tests. |
- const bool use_small_responses_; |
+ bool use_small_responses_; |
// The factor by which the weight of an observation reduces every second. |
const double weight_multiplier_per_second_; |