Commit e0a76104 authored by Michael Achenbach's avatar Michael Achenbach Committed by Commit Bot

[test] Blacklist more flags not suitable for endurance fuzzer

TBR=ulan@chromium.org

Bug: v8:6972
Change-Id: Ibc8405184828337f9a102cbde437c69ec9542816
Reviewed-on: https://chromium-review.googlesource.com/897366Reviewed-by: 's avatarMichael Achenbach <machenbach@chromium.org>
Commit-Queue: Michael Achenbach <machenbach@chromium.org>
Cr-Commit-Position: refs/heads/master@{#51046}
parent b049ac84
...@@ -41,11 +41,16 @@ SELF_SCRIPT_PATTERN = re.compile(r"//\s+Env: TEST_FILE_NAME") ...@@ -41,11 +41,16 @@ SELF_SCRIPT_PATTERN = re.compile(r"//\s+Env: TEST_FILE_NAME")
MODULE_PATTERN = re.compile(r"^// MODULE$", flags=re.MULTILINE) MODULE_PATTERN = re.compile(r"^// MODULE$", flags=re.MULTILINE)
NO_HARNESS_PATTERN = re.compile(r"^// NO HARNESS$", flags=re.MULTILINE) NO_HARNESS_PATTERN = re.compile(r"^// NO HARNESS$", flags=re.MULTILINE)
# Flags known to misbehave when combining arbitrary mjsunit tests. # Flags known to misbehave when combining arbitrary mjsunit tests. Can also
# be compiled regular expressions.
COMBINE_TESTS_FLAGS_BLACKLIST = [ COMBINE_TESTS_FLAGS_BLACKLIST = [
'--check-handle-count', '--check-handle-count',
'--enable-tracing',
re.compile('--experimental.*'),
'--expose-trigger-failure',
'--mock-arraybuffer-allocator', '--mock-arraybuffer-allocator',
'--print-ast', '--print-ast',
re.compile('--trace.*'),
'--wasm-lazy-compilation', '--wasm-lazy-compilation',
] ]
...@@ -233,6 +238,14 @@ class CombinedTest(testcase.TestCase): ...@@ -233,6 +238,14 @@ class CombinedTest(testcase.TestCase):
elif flag1.startswith('-'): elif flag1.startswith('-'):
yield flag1 yield flag1
def _is_flag_blacklisted(self, flag):
for item in COMBINE_TESTS_FLAGS_BLACKLIST:
if isinstance(item, basestring):
if item == flag:
return True
elif item.match(flag):
return True
return False
def _get_combined_flags(self, flags_gen): def _get_combined_flags(self, flags_gen):
"""Combines all flags - dedupes, keeps order and filters some flags. """Combines all flags - dedupes, keeps order and filters some flags.
...@@ -245,7 +258,7 @@ class CombinedTest(testcase.TestCase): ...@@ -245,7 +258,7 @@ class CombinedTest(testcase.TestCase):
unique_flags = OrderedDict((flag, True) for flag in merged_flags).keys() unique_flags = OrderedDict((flag, True) for flag in merged_flags).keys()
return [ return [
flag for flag in unique_flags flag for flag in unique_flags
if flag not in COMBINE_TESTS_FLAGS_BLACKLIST if not self._is_flag_blacklisted(flag)
] ]
def _get_source_flags(self): def _get_source_flags(self):
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment