Skip to content

Fix flaky test in DatadogContextProvider#1726

Merged
xgouchet merged 1 commit into
developfrom
xgouchet/flaky/dd_context_provider
Nov 16, 2023
Merged

Fix flaky test in DatadogContextProvider#1726
xgouchet merged 1 commit into
developfrom
xgouchet/flaky/dd_context_provider

Conversation

@xgouchet

Copy link
Copy Markdown
Contributor

What does this PR do?

Fix a flaky test in the DatadogContextProvider:
the test tries to ensure modifying a mutable map after it being injected won't modify the underlying context.
In some rare case, the following line would create an issue, as no data would be removed from the mutable map, making one of the assertions failed.

The fix ensures that:

  • the original mutable map has at least 4 items
  • at least one entry is removed

@xgouchet
xgouchet requested review from a team as code owners November 16, 2023 10:52
@codecov-commenter

codecov-commenter commented Nov 16, 2023

Copy link
Copy Markdown

Codecov Report

Merging #1726 (da059dc) into develop (50e6072) will decrease coverage by 0.10%.
Report is 8 commits behind head on develop.
The diff coverage is n/a.

Additional details and impacted files
@@             Coverage Diff             @@
##           develop    #1726      +/-   ##
===========================================
- Coverage    83.41%   83.31%   -0.10%     
===========================================
  Files          465      465              
  Lines        16092    16089       -3     
  Branches      2386     2385       -1     
===========================================
- Hits         13422    13404      -18     
- Misses        2025     2047      +22     
+ Partials       645      638       -7     

see 22 files with indirect coverage changes

@xgouchet
xgouchet merged commit 327e7ea into develop Nov 16, 2023
@xgouchet
xgouchet deleted the xgouchet/flaky/dd_context_provider branch November 16, 2023 16:00
@xgouchet xgouchet added this to the 2.3.0 milestone Dec 13, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants