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

Unified Diff: Tools/Scripts/webkitpy/layout_tests/layout_package/bot_test_expectations.py

Issue 301853003: Make update-flaky-tests to work again and support all bots (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Update comments Created 6 years, 7 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/Scripts/webkitpy/layout_tests/layout_package/bot_test_expectations.py
diff --git a/Tools/Scripts/webkitpy/layout_tests/layout_package/bot_test_expectations.py b/Tools/Scripts/webkitpy/layout_tests/layout_package/bot_test_expectations.py
index 4782c1aea5fc5df895648f8a54a5b44461916f07..3d0cd583d98d259f93619403d916d75cee497625 100644
--- a/Tools/Scripts/webkitpy/layout_tests/layout_package/bot_test_expectations.py
+++ b/Tools/Scripts/webkitpy/layout_tests/layout_package/bot_test_expectations.py
@@ -135,16 +135,21 @@ class BotTestExpectations(object):
# FIXME: Get this from the json instead of hard-coding it.
RESULT_TYPES_TO_IGNORE = ['N', 'X', 'Y']
- def __init__(self, results_json):
+ # specifiers arg is used in unittests to avoid the static dependency on builders.
+ def __init__(self, results_json, specifiers=None):
Dirk Pranke 2014/05/29 18:25:21 Can you make specifiers be required and just pass
Dirk Pranke 2014/05/29 21:06:46 I think you missed this comment?
self.results_json = results_json
+ self.specifiers = specifiers or set(builders.specifiers_for_builder(results_json.builder_name))
def _line_from_test_and_flaky_types_and_bug_urls(self, test_path, flaky_types, bug_urls):
line = TestExpectationLine()
line.original_string = test_path
line.name = test_path
line.filename = test_path
- line.specifiers = bug_urls if bug_urls else ""
+ line.path = test_path # FIXME: Should this be normpath?
+ line.matching_tests = [test_path]
+ line.bugs = bug_urls if bug_urls else ["Bug(gardener)"]
line.expectations = sorted(map(self.results_json.expectation_for_type, flaky_types))
+ line.specifiers = self.specifiers
return line
def flakes_by_path(self, only_ignore_very_flaky):

Powered by Google App Engine
This is Rietveld 408576698