-
Notifications
You must be signed in to change notification settings - Fork 98
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
Fix unit tests to avoid data race in pipelines #2602
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #2602 +/- ##
==========================================
- Coverage 89.20% 89.01% -0.19%
==========================================
Files 100 99 -1
Lines 7642 7413 -229
Branches 50 0 -50
==========================================
- Hits 6817 6599 -218
+ Misses 768 757 -11
Partials 57 57 ☔ View full report in Codecov by Sentry. |
9a8dc1e
to
960abbd
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
PR is primarily code so I will not approve, but the documentation explaining the unit tests is clear.
586b5ee
to
063446f
Compare
Fix unit tests to avoid data race in pipelines Problem: Users want to parallelize unit tests without having data race issues Solution: Modify unit tests to be independent of variables, maps/structs to avoid data race when tests run in parallel.
Proposed changes
Write a clear and concise description that helps reviewers understand the purpose and impact of your changes. Use the
following format:
Problem: Users want to parallelize unit tests without having data race issues
Solution: Modify unit tests to be independent of variables, maps/structs to avoid data race when tests run in parallel.
Testing: Manual Testing
make unit-test
10-12 times. Passes all the timehttps://github.com/nginxinc/nginx-gateway-fabric/tree/main/internal/mode/static/state/graph
, where most of the data race failures were happening.Please focus on (optional): If you any specific areas where you would like reviewers to focus their attention or provide
specific feedback, add them here.
Closes #2569
Closes #2578
Checklist
Before creating a PR, run through this checklist and mark each as complete.
Release notes
If this PR introduces a change that affects users and needs to be mentioned in the release notes,
please add a brief note that summarizes the change.