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
Reporter: TapReporter align actual with expected. #107
Reporter: TapReporter align actual with expected. #107
Conversation
When comparing two strings, it is significantly easier to spot the difference when they are aligned. This change pads the label for `actual` with a couple of spaces so that the actual value is printed at the same indentation as the expected value. Previously the expected value was right shifted by 2 characters...
Thoughts? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Must've overlooked this...
Overall, I like it, but I'm wondering if we should align the other fields as well? Or, maybe put the extra space on the other side of :
? Seems kind of odd to me that we force some of the :
to line up but not others.
This certainly looks like an improvement! |
Relevant changes: * Reporter: Align `actual` with `expected` in TapReporter. (Robert Jackson) js-reporters/js-reporters#107
Relevant changes: * Reporter: Align `actual` with `expected` in TapReporter. (Robert Jackson) js-reporters/js-reporters#107
Relevant changes: * Reporter: Align `actual` with `expected` in TapReporter. (Robert Jackson) js-reporters/js-reporters#107
Relevant changes: * Reporter: Align `actual` with `expected` in TapReporter. (Robert Jackson) js-reporters/js-reporters#107
When comparing two strings, it is significantly easier to spot the difference when they are aligned. This change pads the label for
actual
with a couple of spaces so that the actual value is printed at the same indentation as the expected value. Previously the expected value was right shifted by 2 characters...Before:
After: