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

Unified Diff: tools/foozzie/v8_foozzie.py

Issue 2625983002: [foozzie] Add suppressions based on metadata. (Closed)
Patch Set: Correct bug Created 3 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
« no previous file with comments | « no previous file | tools/foozzie/v8_suppressions.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/foozzie/v8_foozzie.py
diff --git a/tools/foozzie/v8_foozzie.py b/tools/foozzie/v8_foozzie.py
index df4c0785a791e0085f2218ff23956928141569f7..34dc86c012278fcbb093c08276c740392d08976c 100755
--- a/tools/foozzie/v8_foozzie.py
+++ b/tools/foozzie/v8_foozzie.py
@@ -148,6 +148,16 @@ def parse_args():
return options
+def metadata_bailout(metadata, ignore_fun):
+ """Print failure state and return if ignore_fun matches metadata."""
+ bug = (ignore_fun(metadata) or '').strip()
+ if bug:
+ print FAILURE_HEADER_TEMPLATE % dict(
+ configs='', sources='', suppression=bug)
+ return True
+ return False
+
+
def test_pattern_bailout(testcase, ignore_fun):
"""Print failure state and return if ignore_fun matches testcase."""
with open(testcase) as f:
@@ -191,13 +201,16 @@ def main():
options.second_arch, options.second_config,
)
- if test_pattern_bailout(options.testcase, suppress.ignore):
- return RETURN_FAIL
-
# Get metadata.
with open(options.meta_data_path) as f:
metadata = json.load(f)
+ if metadata_bailout(metadata, suppress.ignore_by_metadata):
+ return RETURN_FAIL
+
+ if test_pattern_bailout(options.testcase, suppress.ignore_by_content):
+ return RETURN_FAIL
+
common_flags = FLAGS + ['--random-seed', str(options.random_seed)]
first_config_flags = common_flags + CONFIGS[options.first_config]
second_config_flags = common_flags + CONFIGS[options.second_config]
« no previous file with comments | « no previous file | tools/foozzie/v8_suppressions.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698