RFR: 8354510: Skipped gtest cause test failure

Axel Boldt-Christmas aboldtch at openjdk.org
Mon Apr 14 13:32:51 UTC 2025


`GTEST_SKIPPED` tests count is accounted in gtests run. But when we calculate the number of GTEST errors we take `ERROR = RUN - PASSED - FAILED`. We need parse and account for the skipped as well. Currently we only account for `DISABLED` gtests (which are not counted as run tests). 

This patch adds support for both `DISABLED` and `GTEST_SKIPPED` tests.

So with this patch we end up with: 
`ERROR = RUN - PASSED - FAILED - GTEST_SKIPPED`
`SKIPPED = GTEST_SKIPPED + GTEST_DISABLED `

Verified that this works locally on MacOS and Linux. Currently running through testing and GHA. 

_The old `match` expression was problematic with some awk, not sure if there was some other reason it was used, rather than the style used elsewhere `maybe set, if unset set=0`_

-------------

Commit messages:
 - 8354510: Skipped gtest cause test failure

Changes: https://git.openjdk.org/jdk/pull/24622/files
  Webrev: https://webrevs.openjdk.org/?repo=jdk&pr=24622&range=00
  Issue: https://bugs.openjdk.org/browse/JDK-8354510
  Stats: 11 lines in 1 file changed: 0 ins; 1 del; 10 mod
  Patch: https://git.openjdk.org/jdk/pull/24622.diff
  Fetch: git fetch https://git.openjdk.org/jdk.git pull/24622/head:pull/24622

PR: https://git.openjdk.org/jdk/pull/24622


More information about the build-dev mailing list