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

Unified Diff: tools/telemetry/telemetry/page/page_runner.py

Issue 16158006: Defining the test expectations object (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Added expectations integration Created 7 years, 5 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/telemetry/telemetry/page/page_runner.py
diff --git a/tools/telemetry/telemetry/page/page_runner.py b/tools/telemetry/telemetry/page/page_runner.py
index 9ec2d348dc654ad955b6ad52f8ae083897ba6601..009db6830b3af6df413f04bf949771d6221004c9 100644
--- a/tools/telemetry/telemetry/page/page_runner.py
+++ b/tools/telemetry/telemetry/page/page_runner.py
@@ -230,8 +230,12 @@ def Run(test, page_set, options):
if options.profiler_dir:
state.StartProfiling(page, options)
+ expectation = page_set.expectations.GetExpectationForPage(
dtu 2013/07/16 09:50:49 If expectations are tied to the Test instead of th
+ state.browser.platform, page)
+
try:
- _RunPage(test, page, state.tab, results_for_current_run, options)
+ _RunPage(test, page, state.tab, results_for_current_run, options,
+ expectation)
_CheckThermalThrottling(state.browser.platform)
except exceptions.TabCrashException:
stdout = ''
@@ -345,8 +349,10 @@ def _CheckArchives(page_set, pages, results):
pages_missing_archive_path + pages_missing_archive_data]
-def _RunPage(test, page, tab, results, options):
- if not test.CanRunForPage(page):
+def _RunPage(test, page, tab, results, options, expectation):
+ if (expectation == "skip" or
+ expectation == "fail" or
bajones 2013/07/15 23:37:17 In this revision of the code "fail" is being treat
Ken Russell (switch to Gerrit) 2013/07/15 23:52:59 In the "except page_test.Failure" clause below, ca
dtu 2013/07/16 09:50:49 Yep, that's the way to do it.
+ not test.CanRunForPage(page)):
logging.warning('Skipping test: it cannot run for %s', page.url)
results.AddSkip(page, 'Test cannot run')
return
« no previous file with comments | « no previous file | tools/telemetry/telemetry/page/page_set.py » ('j') | tools/telemetry/telemetry/page/page_set.py » ('J')

Powered by Google App Engine
This is Rietveld 408576698