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 regression in BufferedConsole after TS migration #8021

Merged
merged 4 commits into from Mar 2, 2019

Conversation

natealcedo
Copy link
Contributor

@natealcedo natealcedo commented Mar 2, 2019

Summary

This PR is to add an end to end test for #8020.

Fixes #8020

@SimenB
Copy link
Member

SimenB commented Mar 2, 2019

Thanks @natealcedo! This exposed a regression in my migration of jest-util, great we caught it before release 🙂

I pushed a fix and cleaned up the tests

super(
new Writable({
write: message =>
BufferedConsole.write(buffer, 'log', message, null, getSourceMaps()),
Copy link
Member

@SimenB SimenB Mar 2, 2019

Choose a reason for hiding this comment

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

this should have been a type error - message was Buffer, not string

Copy link
Member

Choose a reason for hiding this comment

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

I went with going back to the original implementation anyways, since the stack including lots of internal readable-stream frames. I had to pass 6 a level which felt really brittle

@SimenB SimenB changed the title Add an end to end test for using winston for loggin Fix regression in BufferedConsole after TS migration Mar 2, 2019
@natealcedo
Copy link
Contributor Author

natealcedo commented Mar 2, 2019

Great Stuff @SimenB! Was working on feature I've been thinking about implementing and noticed that the local build was failing on a project from work. I'll open an early PR on that feature to get feedback :)

@codecov-io
Copy link

Codecov Report

Merging #8021 into master will decrease coverage by <.01%.
The diff coverage is 33.33%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #8021      +/-   ##
==========================================
- Coverage   64.11%   64.11%   -0.01%     
==========================================
  Files         262      262              
  Lines       10170    10171       +1     
  Branches     1818     1818              
==========================================
  Hits         6521     6521              
- Misses       3250     3251       +1     
  Partials      399      399
Impacted Files Coverage Δ
packages/jest-util/src/BufferedConsole.ts 70% <33.33%> (-1.43%) ⬇️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 392a815...3012e44. Read the comment docs.

@github-actions
Copy link

This pull request has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.
Please note this issue tracker is not a help forum. We recommend using StackOverflow or our discord channel for questions.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators May 11, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

BufferedConsole doesn't work with winston in master.
4 participants