| Index: tools/chrome_proxy/integration_tests/chrome_proxy_metrics.py
|
| diff --git a/tools/chrome_proxy/integration_tests/chrome_proxy_metrics.py b/tools/chrome_proxy/integration_tests/chrome_proxy_metrics.py
|
| index 3f765bf68ad8d10e4cb2509427d6e9816c7a64e6..541d6877e56815163f6ff9c37138f3d6696571e3 100644
|
| --- a/tools/chrome_proxy/integration_tests/chrome_proxy_metrics.py
|
| +++ b/tools/chrome_proxy/integration_tests/chrome_proxy_metrics.py
|
| @@ -157,6 +157,19 @@ class ChromeProxyMetric(network_metrics.NetworkMetric):
|
| results.AddValue(scalar.ScalarValue(
|
| results.current_page, 'request_bypassed', 'count', bypass_count))
|
|
|
| + def AddResultsForClientVersion(self, tab, results):
|
| + for resp in self.IterResponses(tab):
|
| + r = resp.response
|
| + if resp.response.status != 200:
|
| + raise ChromeProxyMetricException, ('%s: Response is not 200: %d' %
|
| + (r.url, r.status))
|
| + if not resp.IsValidByViaHeader():
|
| + raise ChromeProxyMetricException, ('%s: Response missing via header' %
|
| + (r.url))
|
| + results.AddValue(scalar.ScalarValue(
|
| + results.current_page, 'version_test', 'count', 1))
|
| +
|
| +
|
| def IsProxyBypassed(self, tab):
|
| """ Returns True if all configured proxies are bypassed."""
|
| if not tab:
|
|
|