Skip to content

fix Regex __eq__ method #337

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

Merged
merged 2 commits into from
Sep 29, 2017
Merged

fix Regex __eq__ method #337

merged 2 commits into from
Sep 29, 2017

Conversation

gzcf
Copy link
Contributor

@gzcf gzcf commented Sep 28, 2017

No description provided.

Copy link
Member

@ShaneHarvey ShaneHarvey left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the pull! Can you add yourself to the doc/contributors.rst list?

def test_regex_comparison(self):
re1 = Regex('a')
re2 = Regex('b')
self.assertNotEqual(re1, re2)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you add some more assertions that make sure flags are compared properly too? And an self.assertEqual with two equivalent Regex's?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Of course

Copy link
Member

@ShaneHarvey ShaneHarvey left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! I'm wondering, how did you find this bug?

@ShaneHarvey ShaneHarvey merged commit 9051b65 into mongodb:master Sep 29, 2017
@ShaneHarvey
Copy link
Member

Whoops, linked the wrong ticket in the commit message. It should be PYTHON-1386.

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