Fix test driver output for passes in predictable mode.
authormachenbach@chromium.org <machenbach@chromium.org@ce2b1a6d-e550-0410-aec6-3dcde31c8c00>
Wed, 9 Jul 2014 11:37:36 +0000 (11:37 +0000)
committermachenbach@chromium.org <machenbach@chromium.org@ce2b1a6d-e550-0410-aec6-3dcde31c8c00>
Wed, 9 Jul 2014 11:37:36 +0000 (11:37 +0000)
Passes in predictable mode were wrongly reported as failures by the json progress indicator. This moves control about what is reported completely to execution.py.

BUG=391747
LOG=n
R=ishell@chromium.org, jkummerow@chromium.org

Review URL: https://codereview.chromium.org/382443004

git-svn-id: https://v8.googlecode.com/svn/branches/bleeding_edge@22299 ce2b1a6d-e550-0410-aec6-3dcde31c8c00

tools/testrunner/local/execution.py
tools/testrunner/local/progress.py

index d2d086c..a339eeb 100644 (file)
@@ -138,7 +138,10 @@ class Runner(object):
     else:
       self.succeeded += 1
     self.remaining -= 1
-    self.indicator.HasRun(test, has_unexpected_output)
+    # For the indicator, everything that happens after the first run is treated
+    # as unexpected even if it flakily passes in order to include it in the
+    # output.
+    self.indicator.HasRun(test, has_unexpected_output or test.run > 1)
     if has_unexpected_output:
       # Rerun test failures after the indicator has processed the results.
       self._MaybeRerun(pool, test)
index 2c9f650..8caa58c 100644 (file)
@@ -318,9 +318,9 @@ class JsonTestProgressIndicator(ProgressIndicator):
 
   def HasRun(self, test, has_unexpected_output):
     self.progress_indicator.HasRun(test, has_unexpected_output)
-    if test.run == 1 and not has_unexpected_output:
-      # Omit tests that pass on the first run, but collect output of tests
-      # that pass when rerun.
+    if not has_unexpected_output:
+      # Omit tests that run as expected. Passing tests of reruns after failures
+      # will have unexpected_output to be reported here has well.
       return
 
     self.results.append({