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

Insta adds trailing whitespace for blank lines in inline snapshots #88

Closed
matklad opened this issue Nov 15, 2019 · 0 comments
Closed

Insta adds trailing whitespace for blank lines in inline snapshots #88

matklad opened this issue Nov 15, 2019 · 0 comments

Comments

@matklad
Copy link
Contributor

matklad commented Nov 15, 2019

I've run --force-update-snapshots today. It worked flawlessly for most of the cases, expect this single problem:

image

Here, insta adds leading indentation to the otherwise blank line, which doesn't work great with editors which strip trailing ws on save.

martinvonz added a commit to martinvonz/insta that referenced this issue May 15, 2022
The test added in 816df88 doesn't seem to test what it was
supposed to test - it still passses after replacing `l.is_empty() { 0
} else { indentation }` by just `indentation`. With the change in this
patch, the test fails with that modification.
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

No branches or pull requests

1 participant