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: trim input and output correctly #44

Merged
merged 1 commit into from Jun 12, 2019
Merged

fix: trim input and output correctly #44

merged 1 commit into from Jun 12, 2019

Conversation

merceyz
Copy link
Contributor

@merceyz merceyz commented Jun 12, 2019

What:
Fixed babel-plugin-tester not trimming strings correctly

Why:
When using a formatter that adds an empty line at the end of the string babel-plugin-tester will save the result with this empty line. In subsequent runs, when reading the output file it trims it off, causing the strings to not match.

How:
Call trim at assert.equal for both values and don't trim code passed to formatResult

@codecov-io
Copy link

codecov-io commented Jun 12, 2019

Codecov Report

Merging #44 into master will not change coverage.
The diff coverage is 100%.

Impacted file tree graph

@@          Coverage Diff          @@
##           master    #44   +/-   ##
=====================================
  Coverage     100%   100%           
=====================================
  Files           1      1           
  Lines         129    129           
  Branches       32     32           
=====================================
  Hits          129    129
Impacted Files Coverage Δ
src/index.js 100% <100%> (ø) ⬆️

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 556ca0d...bca5fc7. Read the comment docs.

@kentcdodds kentcdodds merged commit 1d22086 into babel-utils:master Jun 12, 2019
@merceyz merceyz deleted the formatting branch June 12, 2019 20:46
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.

None yet

3 participants