Chromium Code Reviews| Index: net/nqe/throughput_analyzer.h |
| diff --git a/net/nqe/throughput_analyzer.h b/net/nqe/throughput_analyzer.h |
| index 649d76bb68d2fcfbb8e320a20e0a1f81beb70483..3ef78592b0c466fd97591611eb1583435c3ad300 100644 |
| --- a/net/nqe/throughput_analyzer.h |
| +++ b/net/nqe/throughput_analyzer.h |
| @@ -70,6 +70,18 @@ class NET_EXPORT_PRIVATE ThroughputAnalyzer { |
| // Notifies |this| of a change in connection type. |
| void OnConnectionTypeChanged(); |
| + // |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); |
|
mef
2016/06/24 20:10:37
nit: drop '_for_tests' for consistency.
tbansal1
2016/06/24 22:41:39
Done.
|
| + |
| + // |use_smaller_responses_for_tests| should only be true when testing, and |
| + // allows the responses smaller than |kMinTransferSizeInBits| or shorter than |
| + // |kMinRequestDurationMicroseconds| to be used for network quality |
| + // estimation. |
| + void SetUseSmallResponsesForTesting(bool use_small_responses); |
| + |
| protected: |
| // Exposed for testing. |
| bool disable_throughput_measurements() const { |
| @@ -155,12 +167,12 @@ class NET_EXPORT_PRIVATE ThroughputAnalyzer { |
| // 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_for_tests_; |
| + bool use_localhost_requests_for_tests_; |
| // Determines if the responses smaller than |kMinTransferSizeInBits| |
| // or shorter than |kMinTransferSizeInBits| can be used in estimating the |
| // network quality. Set to true only for tests. |
| - const bool use_small_responses_for_tests_; |
| + bool use_small_responses_for_tests_; |
| base::ThreadChecker thread_checker_; |