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

fix: error with pretty-print and jest #342

Merged
merged 2 commits into from
Dec 11, 2023
Merged

fix: error with pretty-print and jest #342

merged 2 commits into from
Dec 11, 2023

Conversation

yoshutch
Copy link
Contributor

@yoshutch yoshutch commented Dec 8, 2023

jest detected hanging functions and I believe it's pino-pretty and jest don't work well together.

https://github.com/pinojs/pino-pretty?tab=readme-ov-file#usage-with-jest

I've tried adding the sync property and that doesn't seem to help. So instead we can just default to not include pretty print if we're running tests. I suspect that the real issue is that jest with pretty print seem to introduce a race condition that doesn't always finish before jest finishes.

jest detected hanging functions and I believe it's the translateTime pretty print option was not correct
@yoshutch yoshutch requested a review from stuft2 December 8, 2023 23:20
Copy link

codecov bot commented Dec 8, 2023

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (d2f92f8) 80.00% compared to head (d283b16) 72.00%.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #342      +/-   ##
==========================================
- Coverage   80.00%   72.00%   -8.00%     
==========================================
  Files           2        2              
  Lines          25       25              
  Branches        6        6              
==========================================
- Hits           20       18       -2     
- Misses          5        7       +2     

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

@yoshutch yoshutch requested a review from a team December 11, 2023 16:40
@yoshutch yoshutch merged commit 4f612b1 into main Dec 11, 2023
4 checks passed
@yoshutch yoshutch deleted the fix/pretty branch December 11, 2023 16:48
Copy link
Contributor

@stuft2 stuft2 left a comment

Choose a reason for hiding this comment

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

LGTM

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.

3 participants