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

Shortcut for building patch sets from strings #34

Closed
wants to merge 8 commits into from

Conversation

gwerbin
Copy link

@gwerbin gwerbin commented Oct 17, 2016

Adds a class method to PatchSet that wraps a string in StringIO, to be read by __init__.

Addresses #26

Adds a class method to PatchSet that wraps a string in StringIO, to be read by __init__.
@matiasb
Copy link
Owner

matiasb commented Oct 24, 2016

Looks good, would you add a test for it?

@gwerbin
Copy link
Author

gwerbin commented Oct 30, 2016

The tests are failing on my machine, but I'm not totally sure why (the loaded patch sets themselves look identical when printed). Any insight?

@matiasb
Copy link
Owner

matiasb commented Nov 12, 2016

Hey, I was just checking this. The problem is that the default implementation of eq in the Line object does not work as we would like (by default it uses the id of objects for comparison), and that's why expected != actual.
I'll prepare some changes, and once that's fixed (and you rebase your branch) hopefully tests should pass.
Thanks for adding the tests!

@matiasb
Copy link
Owner

matiasb commented Nov 17, 2016

I merged the PR implementing eq for lines, if you rebase when you get a few minutes, I would expect your tests to pass.

@matiasb
Copy link
Owner

matiasb commented May 20, 2017

Added from_string to master (with minor changes), thanks for the PR!

@matiasb matiasb closed this May 20, 2017
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.

2 participants