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

Side by Side Diff: tools/chrome_proxy/integration_tests/chrome_proxy_measurements.py

Issue 959423003: Telemetry: Add more details to inspector_backend exceptions. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@telemetry_make_new_exceptions4
Patch Set: Rebase against top of tree. Created 5 years, 9 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 unified diff | Download patch
« no previous file with comments | « no previous file | tools/perf/profile_creators/fast_navigation_profile_extender.py » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 import base64 5 import base64
6 import logging 6 import logging
7 import urlparse 7 import urlparse
8 8
9 from integration_tests import chrome_proxy_metrics as metrics 9 from integration_tests import chrome_proxy_metrics as metrics
10 from metrics import loading 10 from metrics import loading
(...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after
86 return True 86 return True
87 return False 87 return False
88 88
89 def RunNavigateSteps(self, page, tab): 89 def RunNavigateSteps(self, page, tab):
90 # The redirect from safebrowsing causes a timeout. Ignore that. 90 # The redirect from safebrowsing causes a timeout. Ignore that.
91 try: 91 try:
92 super(ChromeProxyValidation, self).RunNavigateSteps(page, tab) 92 super(ChromeProxyValidation, self).RunNavigateSteps(page, tab)
93 if self._expect_timeout: 93 if self._expect_timeout:
94 raise metrics.ChromeProxyMetricException, ( 94 raise metrics.ChromeProxyMetricException, (
95 'Timeout was expected, but did not occur') 95 'Timeout was expected, but did not occur')
96 except exceptions.DevtoolsTargetCrashException, e: 96 except exceptions.TimeoutException as e:
97 if self._expect_timeout: 97 if self._expect_timeout:
98 logging.warning('Navigation timeout on page %s', 98 logging.warning('Navigation timeout on page %s',
99 page.name if page.name else page.url) 99 page.name if page.name else page.url)
100 else: 100 else:
101 raise e 101 raise e
102 102
103 103
104 class ChromeProxyHeaders(ChromeProxyValidation): 104 class ChromeProxyHeaders(ChromeProxyValidation):
105 """Correctness measurement for response headers.""" 105 """Correctness measurement for response headers."""
106 106
(...skipping 271 matching lines...) Expand 10 before | Expand all | Expand 10 after
378 self._metrics.AddResultsForDataSaving, 378 self._metrics.AddResultsForDataSaving,
379 ], 379 ],
380 'bypass': [self._metrics.AddResultsForBypass], 380 'bypass': [self._metrics.AddResultsForBypass],
381 } 381 }
382 if not self._page.name in page_to_metrics: 382 if not self._page.name in page_to_metrics:
383 raise page_test.MeasurementFailure( 383 raise page_test.MeasurementFailure(
384 'Invalid page name (%s) in smoke. Page name must be one of:\n%s' % ( 384 'Invalid page name (%s) in smoke. Page name must be one of:\n%s' % (
385 self._page.name, page_to_metrics.keys())) 385 self._page.name, page_to_metrics.keys()))
386 for add_result in page_to_metrics[self._page.name]: 386 for add_result in page_to_metrics[self._page.name]:
387 add_result(tab, results) 387 add_result(tab, results)
OLDNEW
« no previous file with comments | « no previous file | tools/perf/profile_creators/fast_navigation_profile_extender.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698