Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(22)

Unified Diff: tools/chrome_proxy/integration_tests/chrome_proxy_metrics_unittest.py

Issue 792303006: Remove the net-internals dependency from chrome proxy telemetry tests. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: tools/chrome_proxy/integration_tests/chrome_proxy_metrics_unittest.py
diff --git a/tools/chrome_proxy/integration_tests/chrome_proxy_metrics_unittest.py b/tools/chrome_proxy/integration_tests/chrome_proxy_metrics_unittest.py
index 37fdb5f9f3babec82c226bd275cb9cb06a5dff7d..c1321d0d70b92ea8e3da71e04fc9910cfe00a346 100644
--- a/tools/chrome_proxy/integration_tests/chrome_proxy_metrics_unittest.py
+++ b/tools/chrome_proxy/integration_tests/chrome_proxy_metrics_unittest.py
@@ -206,45 +206,6 @@ class ChromeProxyMetricTest(unittest.TestCase):
metric.AddResultsForCorsBypass(None, results)
results.AssertHasPageSpecificScalarValue('cors_bypass', 'count', 1)
bolian 2015/01/14 07:01:04 Also add test for the new funcs? At least add a T
sclittle 2015/01/14 19:20:51 Sure, I've added new unit tests, except for Reenab
-
- def testChromeProxyMetricForHTTPFallback(self):
- metric = metrics.ChromeProxyMetric()
- metric.SetEvents([
- EVENT_HTML_PROXY,
- EVENT_HTML_PROXY_DEPRECATED_VIA])
- results = test_page_test_results.TestPageTestResults(self)
-
- fallback_exception = False
- info = {}
- info['enabled'] = False
- self._StubGetProxyInfo(info)
- try:
- metric.AddResultsForBypass(None, results)
- except metrics.ChromeProxyMetricException:
- fallback_exception = True
- self.assertTrue(fallback_exception)
-
- fallback_exception = False
- info['enabled'] = True
- info['proxies'] = [
- 'something.else.com:80',
- metrics.PROXY_SETTING_DIRECT
- ]
- self._StubGetProxyInfo(info)
- try:
- metric.AddResultsForBypass(None, results)
- except metrics.ChromeProxyMetricException:
- fallback_exception = True
- self.assertTrue(fallback_exception)
-
- info['enabled'] = True
- info['proxies'] = [
- metrics.PROXY_SETTING_HTTP,
- metrics.PROXY_SETTING_DIRECT
- ]
- self._StubGetProxyInfo(info)
- metric.AddResultsForHTTPFallback(None, results)
-
def testChromeProxyMetricForSafebrowsing(self):
metric = metrics.ChromeProxyMetric()
metric.SetEvents([EVENT_MALWARE_PROXY])

Powered by Google App Engine
This is Rietveld 408576698