-
Notifications
You must be signed in to change notification settings - Fork 44
TT-1995 Prevent double-counting of test failures in Flakeguard #1665
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
…st-transformer-Flakeguard-integration
* Integrate go test transformer into Flakeguard * Fix * Update test
…smartcontractkit/chainlink-testing-framework into TT-1995-add-go-test-transformer
|
kalverra
approved these changes
Mar 4, 2025
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.




This PR introduces a custom Go Test JSON transformer and integrates it into Flakeguard to enhance test failure reporting.
Key Changes:
New Go Test JSON Transformer - Transforms
go test -jsonoutput to ensure that parent tests are not marked as failures when only their subtests fail (i.e., no direct parent failure).Flakeguard Integration - The transformer is integrated into Flakeguard to fix TT-1995, preventing the double-counting of test failures.
Flakeguard Summary Report Updates - Added improvements to the Flakeguard Summary report.
The transformer is now tested with real data using the Flakeguard Nightly Workflow in core repo, ensuring accuracy and reliability in real scenarios.
To Do:
Below is a summarization created by an LLM (gpt-4-0125-preview). Be mindful of hallucinations and verify accuracy.
Why
The changes introduce a new feature to ignore parent test failures when only their subtests fail, enhancing the test result analysis process. This is particularly useful in large test suites where failing subtests may not necessarily indicate a problem with the parent test logic itself. Additionally, the presentation of flaky and panicked tests has been improved in the summary table for better clarity.
What
tools/flakeguard/cmd/run.go: Added a new flagignore-parent-failures-on-subteststo enable the feature of ignoring parent test failures when only subtests fail.tools/flakeguard/go-test-transform/README.md: Created a README file for the go-test-transform utility, explaining its purpose, features, and usage.tools/flakeguard/go-test-transform/cmd/main.go: Implemented the main command for the go-test-transform utility, including command-line flags for input/output options and the ignore-all mechanism.tools/flakeguard/go-test-transform/pkg/transformer/options.go: Defined options for the test transformer, specifically the option to ignore all subtest failures.tools/flakeguard/go-test-transform/pkg/transformer/transformer.go: Implemented the logic for transforming go test JSON output to handle subtest failures more intelligently.tools/flakeguard/go-test-transform/pkg/transformer/transformer_test.go: Added comprehensive tests to verify the correct behavior of the transformer logic under various scenarios, including handling special characters in test names and dealing with fuzz tests.tools/flakeguard/reports/presentation.go: Modified the summary table rendering to include rows for unique flaky tests and unique panicked tests, improving the presentation of test results.tools/flakeguard/runner/runner.go: Integrated the go-test-transform utility's transformation logic into the test runner to apply the ignore parent failures feature and handle transformed output files.