diff options
author | 2017-02-02 10:19:15 +0000 | |
---|---|---|
committer | 2017-02-02 16:59:54 +0000 | |
commit | 1f452c3db426a472a30f09c2ed6594fe1fa50749 (patch) | |
tree | 79d6ef9ac7d25d374d0fb11160ad08540e474308 /src/test/shell | |
parent | 590188dfec07bd18a9dfeb292de40635dad139b5 (diff) |
Also report individual test results via BEP
Only having a test summary for each test target is not enough for timely
error reporting. Also individual test actions and attempts are of interest.
Report those by making TestResult an instance of BuildEvent.
--
Change-Id: Iee1c988b6d467ebda8230b9edacbe3b66600c30e
Reviewed-on: https://cr.bazel.build/8532
PiperOrigin-RevId: 146342845
MOS_MIGRATED_REVID=146342845
Diffstat (limited to 'src/test/shell')
-rwxr-xr-x | src/test/shell/integration/build_event_stream_test.sh | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/src/test/shell/integration/build_event_stream_test.sh b/src/test/shell/integration/build_event_stream_test.sh index e26d627f2a..315e2239c3 100755 --- a/src/test/shell/integration/build_event_stream_test.sh +++ b/src/test/shell/integration/build_event_stream_test.sh @@ -81,6 +81,22 @@ function test_test_summary() { expect_not_log 'aborted' } +function test_test_inidivual_results() { + # Requesting a test, we expect + # - precisely one test summary (for the single test we run) + # - that is properly chained (no additional progress events) + bazel test --experimental_build_event_text_file=$TEST_log \ + --runs_per_test=2 pkg:true \ + || fail "bazel test failed" + expect_log '^test_result' + expect_log 'run.*1' + expect_log 'success.*true' + expect_log_once '^test_summary ' + expect_log_once '^progress ' + expect_not_log 'aborted' +} + + function test_build_only() { # When building but not testing a test, there won't be a test summary # (as nothing was tested), so it should not be announced. |