| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "components/data_reduction_proxy/core/browser/data_reduction_proxy_bypa
ss_stats.h" | 5 #include "components/data_reduction_proxy/core/browser/data_reduction_proxy_bypa
ss_stats.h" |
| 6 | 6 |
| 7 #include <stddef.h> | 7 #include <stddef.h> |
| 8 #include <stdint.h> | 8 #include <stdint.h> |
| 9 | 9 |
| 10 #include <set> | 10 #include <set> |
| 11 #include <string> | 11 #include <string> |
| 12 #include <vector> | 12 #include <vector> |
| 13 | 13 |
| 14 #include "base/bind.h" | 14 #include "base/bind.h" |
| 15 #include "base/macros.h" | 15 #include "base/macros.h" |
| 16 #include "base/memory/scoped_ptr.h" | 16 #include "base/memory/scoped_ptr.h" |
| 17 #include "base/metrics/histogram.h" | 17 #include "base/metrics/histogram.h" |
| 18 #include "base/prefs/testing_pref_service.h" |
| 18 #include "base/test/histogram_tester.h" | 19 #include "base/test/histogram_tester.h" |
| 19 #include "components/data_reduction_proxy/core/browser/data_reduction_proxy_conf
ig_test_utils.h" | 20 #include "components/data_reduction_proxy/core/browser/data_reduction_proxy_conf
ig_test_utils.h" |
| 20 #include "components/data_reduction_proxy/core/browser/data_reduction_proxy_conf
igurator.h" | 21 #include "components/data_reduction_proxy/core/browser/data_reduction_proxy_conf
igurator.h" |
| 21 #include "components/data_reduction_proxy/core/browser/data_reduction_proxy_io_d
ata.h" | 22 #include "components/data_reduction_proxy/core/browser/data_reduction_proxy_io_d
ata.h" |
| 22 #include "components/data_reduction_proxy/core/browser/data_reduction_proxy_netw
ork_delegate.h" | 23 #include "components/data_reduction_proxy/core/browser/data_reduction_proxy_netw
ork_delegate.h" |
| 23 #include "components/data_reduction_proxy/core/browser/data_reduction_proxy_pref
s.h" | 24 #include "components/data_reduction_proxy/core/browser/data_reduction_proxy_pref
s.h" |
| 24 #include "components/data_reduction_proxy/core/browser/data_reduction_proxy_test
_utils.h" | 25 #include "components/data_reduction_proxy/core/browser/data_reduction_proxy_test
_utils.h" |
| 25 #include "components/data_reduction_proxy/core/common/data_reduction_proxy_heade
rs_test_utils.h" | 26 #include "components/data_reduction_proxy/core/common/data_reduction_proxy_heade
rs_test_utils.h" |
| 26 #include "components/data_reduction_proxy/core/common/data_reduction_proxy_param
s_test_utils.h" | 27 #include "components/data_reduction_proxy/core/common/data_reduction_proxy_param
s_test_utils.h" |
| 27 #include "components/data_reduction_proxy/core/common/data_reduction_proxy_pref_
names.h" | 28 #include "components/data_reduction_proxy/core/common/data_reduction_proxy_pref_
names.h" |
| 28 #include "components/prefs/testing_pref_service.h" | |
| 29 #include "net/base/host_port_pair.h" | 29 #include "net/base/host_port_pair.h" |
| 30 #include "net/base/load_flags.h" | 30 #include "net/base/load_flags.h" |
| 31 #include "net/base/net_errors.h" | 31 #include "net/base/net_errors.h" |
| 32 #include "net/base/request_priority.h" | 32 #include "net/base/request_priority.h" |
| 33 #include "net/dns/mock_host_resolver.h" | 33 #include "net/dns/mock_host_resolver.h" |
| 34 #include "net/http/http_response_headers.h" | 34 #include "net/http/http_response_headers.h" |
| 35 #include "net/http/http_util.h" | 35 #include "net/http/http_util.h" |
| 36 #include "net/log/net_log.h" | 36 #include "net/log/net_log.h" |
| 37 #include "net/socket/socket_test_util.h" | 37 #include "net/socket/socket_test_util.h" |
| 38 #include "net/url_request/url_request.h" | 38 #include "net/url_request/url_request.h" |
| (...skipping 903 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 942 histogram_tester.ExpectUniqueSample( | 942 histogram_tester.ExpectUniqueSample( |
| 943 "DataReductionProxy.BypassedBytes.NetworkErrorOther", kBody.size(), 1); | 943 "DataReductionProxy.BypassedBytes.NetworkErrorOther", kBody.size(), 1); |
| 944 ExpectOtherBypassedBytesHistogramsEmpty( | 944 ExpectOtherBypassedBytesHistogramsEmpty( |
| 945 histogram_tester, "DataReductionProxy.BypassedBytes.NetworkErrorOther"); | 945 histogram_tester, "DataReductionProxy.BypassedBytes.NetworkErrorOther"); |
| 946 histogram_tester.ExpectUniqueSample( | 946 histogram_tester.ExpectUniqueSample( |
| 947 "DataReductionProxy.BypassOnNetworkErrorPrimary", | 947 "DataReductionProxy.BypassOnNetworkErrorPrimary", |
| 948 -net::ERR_PROXY_CONNECTION_FAILED, 1); | 948 -net::ERR_PROXY_CONNECTION_FAILED, 1); |
| 949 } | 949 } |
| 950 | 950 |
| 951 } // namespace data_reduction_proxy | 951 } // namespace data_reduction_proxy |
| OLD | NEW |