[test] Expose variant flags in json output

For standard test failures, the variant name is enough to deduce the
full command line of the test. This is used to create the flako
command line on the infra side.

Test failures from numfuzz have additional variant_flags, calculated
by the fuzzer, which don't match a variant name. Exposing those in
the test results will enable printing a proper flako command line
on infra side for numfuzz cases.

Bug: v8:8971
Change-Id: Ie47d42a0b34037da458b474f2a9ab38f1a5d238a
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/1554689
Reviewed-by: Sergiy Belozorov <sergiyb@chromium.org>
Commit-Queue: Michael Achenbach <machenbach@chromium.org>
Cr-Commit-Position: refs/heads/master@{#60656}
This commit is contained in:
Michael Achenbach 2019-04-05 15:08:57 +02:00 committed by Commit Bot
parent 165eb80115
commit ff0b9dd30e
3 changed files with 11 additions and 5 deletions

View File

@ -307,6 +307,7 @@ class JsonTestProgressIndicator(ProgressIndicator):
"random_seed": test.random_seed, "random_seed": test.random_seed,
"target_name": test.get_shell(), "target_name": test.get_shell(),
"variant": test.variant, "variant": test.variant,
"variant_flags": test.variant_flags,
}) })
def finished(self): def finished(self):

View File

@ -23,7 +23,8 @@
"stderr": "", "stderr": "",
"stdout": "--test strawberries --random-seed=123 --nohard-abort\n", "stdout": "--test strawberries --random-seed=123 --nohard-abort\n",
"target_name": "d8_mocked.py", "target_name": "d8_mocked.py",
"variant": "default" "variant": "default",
"variant_flags": []
}, },
{ {
"command": "/usr/bin/python out/Release/d8_mocked.py --test strawberries --random-seed=123 --nohard-abort", "command": "/usr/bin/python out/Release/d8_mocked.py --test strawberries --random-seed=123 --nohard-abort",
@ -45,7 +46,8 @@
"stderr": "", "stderr": "",
"stdout": "--test strawberries --random-seed=123 --nohard-abort\n", "stdout": "--test strawberries --random-seed=123 --nohard-abort\n",
"target_name": "d8_mocked.py", "target_name": "d8_mocked.py",
"variant": "default" "variant": "default",
"variant_flags": []
}, },
{ {
"command": "/usr/bin/python out/Release/d8_mocked.py --test strawberries --random-seed=123 --nohard-abort", "command": "/usr/bin/python out/Release/d8_mocked.py --test strawberries --random-seed=123 --nohard-abort",
@ -67,7 +69,8 @@
"stderr": "", "stderr": "",
"stdout": "--test strawberries --random-seed=123 --nohard-abort\n", "stdout": "--test strawberries --random-seed=123 --nohard-abort\n",
"target_name": "d8_mocked.py", "target_name": "d8_mocked.py",
"variant": "default" "variant": "default",
"variant_flags": []
} }
], ],
"slowest_tests": [ "slowest_tests": [

View File

@ -22,7 +22,8 @@
"stderr": "", "stderr": "",
"stdout": "bananaflakes --random-seed=123 --nohard-abort\n", "stdout": "bananaflakes --random-seed=123 --nohard-abort\n",
"target_name": "d8_mocked.py", "target_name": "d8_mocked.py",
"variant": "default" "variant": "default",
"variant_flags": []
}, },
{ {
"command": "/usr/bin/python out/Release/d8_mocked.py bananaflakes --random-seed=123 --nohard-abort", "command": "/usr/bin/python out/Release/d8_mocked.py bananaflakes --random-seed=123 --nohard-abort",
@ -43,7 +44,8 @@
"stderr": "", "stderr": "",
"stdout": "bananaflakes --random-seed=123 --nohard-abort\n", "stdout": "bananaflakes --random-seed=123 --nohard-abort\n",
"target_name": "d8_mocked.py", "target_name": "d8_mocked.py",
"variant": "default" "variant": "default",
"variant_flags": []
} }
], ],
"slowest_tests": [ "slowest_tests": [