| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
Sorry, something went wrong.
|
Review requested:
|
Sorry, something went wrong.
Codecov Report✅ All modified and coverable lines are covered by tests. @@ Coverage Diff @@
## main #58063 +/- ##
=======================================
Coverage 90.21% 90.21%
=======================================
Files 630 630
Lines 186391 186448 +57
Branches 36610 36620 +10
=======================================
+ Hits 168146 168209 +63
+ Misses 11066 11038 -28
- Partials 7179 7201 +22
... and 34 files with indirect coverage changes 🚀 New features to boost your workflow:
|
Sorry, something went wrong.
Please don't do that, we discussed it a lot. Those refactors are not useful. |
Sorry, something went wrong.
oh okay, surprising because the use cases with the it allow you to find your way around the test and, in the event of a failure, search the codebase. |
Sorry, something went wrong.
Sorry, something went wrong.
| @@ -129,8 +128,9 @@ function styleText(format, text, { validateStream = true, stream = process.stdou | |||
| throw new ERR_INVALID_ARG_TYPE('stream', ['ReadableStream', 'WritableStream', 'Stream'], stream); | |||
| } | |||
|
|
|||
| // If the stream is falsy or should not be colorized, set skipColorize to true | |||
| skipColorize = !lazyUtilColors().shouldColorize(stream); | |||
| if (!lazyUtilColors().shouldColorize(stream)) { | |||
There was a problem hiding this comment.
early return will skip validation so its a necessary overhead
#56722 (comment)
Sorry, something went wrong.
There was a problem hiding this comment.
As Marco mentioned, the "overhead" is necessary.
Sorry, something went wrong.
|
Can I just keep benchmark change ? |
Sorry, something went wrong.
Yes, but I'd do it as a separate benchmark, so we don't need to have benchmarks for: noColors: true, format: 'italic', As they will all be the same. So, adding it as a separate benchmark makes more sense. |
Sorry, something went wrong.
Co-Authored-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
| validateStream: [1, 0], | ||
| n: [1e3], | ||
| }); | ||
| withColor: { |
There was a problem hiding this comment.
Please, create a different file instead. style-text-nocolor.js
Sorry, something went wrong.
There was a problem hiding this comment.
oh okay got it !
Sorry, something went wrong.
|
This pull request has been marked as stale due to 210 days of inactivity. |
Sorry, something went wrong.
| Back | FazBrowse Home | New Git URL |
I had modify logic behind. using a reducer, it's should be quicker. And I had updated benchmark
Plus I had updated test to use node:test in goal of having better DX when something fails.