Skip to content

MINOR Handle test re-runs in junit.py#17034

Merged
chia7712 merged 6 commits into
apache:trunkfrom
mumrah:gh-junit-flaky-tests
Aug 31, 2024
Merged

MINOR Handle test re-runs in junit.py#17034
chia7712 merged 6 commits into
apache:trunkfrom
mumrah:gh-junit-flaky-tests

Conversation

@mumrah

@mumrah mumrah commented Aug 28, 2024

Copy link
Copy Markdown
Member

Since we are using the Develocity retry test feature, it is possible to see a test fail and also pass in the same suite. Add support to this for the junit report generation. Also move the skipped tests into a different table.

@mumrah mumrah added the build Gradle build or GitHub Actions label Aug 28, 2024
@mumrah

mumrah commented Aug 29, 2024

Copy link
Copy Markdown
Member Author

The "Details" link in the PR status check takes you to the failure in the workflow. I've added console logs so we can see the test failures right away.

image

The markdown summary now includes separate tables for failed, flaky, and skipped tests.

image

@mumrah mumrah requested a review from chia7712 August 29, 2024 19:50

@chia7712 chia7712 left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mumrah thanks for this great parser! one question is left

Comment thread .github/scripts/junit.py Outdated
report_md = f"Download [HTML report]({report_url})."
summary = f"{total_tests} tests run in {duration}, {total_failures} failed ❌, {total_skipped} skipped ⚠️, {total_errors} errors."
logger.debug(summary)
summary = f"{total_tests} tests run in {duration}, {total_failures} {FAILED}, {total_flaky} {FLAKY}, {total_skipped} {SKIPPED}, and {total_errors} errors."

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The tests shown by "Failed Tests" table exclude the "flaky". Does it confuse readers that the "number of failed" is NOT equal to the number of tests shown by "Failed Tests" table.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, I noticed this too. Latest commit should fix this

@mumrah mumrah requested a review from chia7712 August 30, 2024 19:18
@mumrah

mumrah commented Aug 31, 2024

Copy link
Copy Markdown
Member Author

Latest run shows the tables match the summary count. https://github.com/apache/kafka/actions/runs/10638037021?pr=17034

@chia7712 chia7712 merged commit 3efa785 into apache:trunk Aug 31, 2024
mumrah added a commit to mumrah/kafka that referenced this pull request Sep 1, 2024
Reviewers: Chia-Ping Tsai <chia7712@gmail.com>
bboyleonp666 pushed a commit to bboyleonp666/kafka that referenced this pull request Sep 4, 2024
Reviewers: Chia-Ping Tsai <chia7712@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

build Gradle build or GitHub Actions

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants