Skip to content
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

Use fake/fixed date in unit tests #2091

Merged
merged 2 commits into from
Jan 5, 2024
Merged

Conversation

yurishkuro
Copy link
Member

Which problem is this PR solving?

Description of the changes

  • Mock the current date to a fix value to avoid time of year variations in behavior

@yurishkuro yurishkuro requested a review from a team as a code owner January 5, 2024 16:41
@yurishkuro yurishkuro requested review from jkowall and removed request for a team January 5, 2024 16:41
@yurishkuro yurishkuro added the changelog:test Change that's adding missing tests or correcting existing tests label Jan 5, 2024
Copy link

codecov bot commented Jan 5, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (911ccf5) 96.56% compared to head (0a0430f) 96.57%.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #2091      +/-   ##
==========================================
+ Coverage   96.56%   96.57%   +0.01%     
==========================================
  Files         254      254              
  Lines        7620     7620              
  Branches     1986     1986              
==========================================
+ Hits         7358     7359       +1     
+ Misses        262      261       -1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Signed-off-by: Yuri Shkuro <[email protected]>
@yurishkuro yurishkuro merged commit 868bb05 into jaegertracing:main Jan 5, 2024
10 checks passed
@yurishkuro yurishkuro deleted the fix-2090 branch January 5, 2024 16:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
changelog:test Change that's adding missing tests or correcting existing tests
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Bug]: Unit tests in src/utils/date.test.js fail in early January
1 participant