diff options
author | 2016-06-09 08:46:29 +0000 | |
---|---|---|
committer | 2016-06-09 11:27:06 +0000 | |
commit | dca18400dd00da500accd447d1d3cfc248956478 (patch) | |
tree | f7b7331b8c31723298a8638ca5f5cba7d9dc2484 | |
parent | b5692bde922c042066a979f9275657648e16d79d (diff) |
experimental ui: not only report errors, but also failures immediately
When a user is running a test with lots of runs (e.g., to debug flakyness),
it is useful to immediately see individual failures and not wait for the
summary of tests. Therefore, report failure events just like errors in the
scrollback buffer.
--
Change-Id: If32d1201f59cec75d99d18a50fc881c3596c3081
Reviewed-on: https://bazel-review.googlesource.com/#/c/3770
MOS_MIGRATED_REVID=124437705
-rw-r--r-- | src/main/java/com/google/devtools/build/lib/runtime/ExperimentalEventHandler.java | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/src/main/java/com/google/devtools/build/lib/runtime/ExperimentalEventHandler.java b/src/main/java/com/google/devtools/build/lib/runtime/ExperimentalEventHandler.java index 4652907ace..09720400ef 100644 --- a/src/main/java/com/google/devtools/build/lib/runtime/ExperimentalEventHandler.java +++ b/src/main/java/com/google/devtools/build/lib/runtime/ExperimentalEventHandler.java @@ -149,6 +149,7 @@ public class ExperimentalEventHandler extends BlazeCommandEventHandler { } break; case ERROR: + case FAIL: case WARNING: case INFO: case SUBCOMMAND: @@ -181,6 +182,13 @@ public class ExperimentalEventHandler extends BlazeCommandEventHandler { if (stateTracker.progressBarTimeDependent()) { refresh(); } + break; + case START: + case FINISH: + case PASS: + case TIMEOUT: + case DEPCHECKER: + break; } } } catch (IOException e) { @@ -191,6 +199,7 @@ public class ExperimentalEventHandler extends BlazeCommandEventHandler { private void setEventKindColor(EventKind kind) throws IOException { switch (kind) { case ERROR: + case FAIL: terminal.textRed(); terminal.textBold(); break; @@ -202,6 +211,9 @@ public class ExperimentalEventHandler extends BlazeCommandEventHandler { break; case SUBCOMMAND: terminal.textBlue(); + break; + default: + terminal.resetTerminal(); } } @@ -286,6 +298,7 @@ public class ExperimentalEventHandler extends BlazeCommandEventHandler { terminal.writeString("FAIL: "); terminal.resetTerminal(); terminal.writeString(summary.getTarget().getLabel().toString()); + terminal.writeString(" (Summary)"); crlf(); for (Path logPath : summary.getFailedLogs()) { terminal.writeString(" " + logPath.getPathString()); |