Index: tools/chrome_proxy/integration_tests/chrome_proxy_measurements.py |
diff --git a/tools/chrome_proxy/integration_tests/chrome_proxy_measurements.py b/tools/chrome_proxy/integration_tests/chrome_proxy_measurements.py |
index 00ba5b57eb48be98fe3ec930371036a6123f0548..ae3b8850128687d9c6c6855d7228ce4afc8b06c3 100644 |
--- a/tools/chrome_proxy/integration_tests/chrome_proxy_measurements.py |
+++ b/tools/chrome_proxy/integration_tests/chrome_proxy_measurements.py |
@@ -260,6 +260,26 @@ class ChromeProxyClientVersion(ChromeProxyValidation): |
self._metrics.AddResultsForClientVersion(tab, results) |
+class ChromeProxyHTTPToDirectFallback(ChromeProxyValidation): |
+ """Correctness measurement for HTTP proxy fallback to direct.""" |
+ |
+ def __init__(self): |
+ super(ChromeProxyHTTPToDirectFallback, self).__init__( |
+ restart_after_each_page=True) |
+ |
+ def WillNavigateToPage(self, page, tab): |
+ super(ChromeProxyHTTPToDirectFallback, self).WillNavigateToPage(page, tab) |
+ proxies = [ |
+ self._metrics.effective_proxies['proxy'], |
+ self._metrics.effective_proxies['fallback'], |
+ self._metrics.effective_proxies['direct']] |
+ bad_proxies = [self._metrics.effective_proxies['proxy']] |
+ self._metrics.VerifyProxyInfo(tab, proxies, bad_proxies) |
bolian
2014/10/14 06:00:49
Why there is bad proxy already before navigation?
sclittle
2014/10/14 17:36:45
Added a comment.
In order to have the test run st
|
+ |
+ def AddResults(self, tab, results): |
+ self._metrics.AddResultsForHTTPToDirectFallback(tab, results) |
+ |
+ |
class ChromeProxySmoke(ChromeProxyValidation): |
"""Smoke measurement for basic chrome proxy correctness.""" |