Open
Conversation
suutari-ai
reviewed
Nov 15, 2018
17750da to
14def4f
Compare
suutari-ai
reviewed
Nov 15, 2018
| def test_sanitize_email_resets_on_session_reset(): | ||
| assert user.sanitize_email('test@example.com') == ( | ||
| 'zoe.burke@xce13103b.sanitized.net') | ||
| assert user.sanitize_email('test@example.net') == ( |
Member
There was a problem hiding this comment.
You can't change the source address and expect it to sanitize to same value. :)
Contributor
Author
There was a problem hiding this comment.
Ah.. we had the random hash there. 👍 Will check what it gave and update the expected value. I think having different source domain helps to understand the functionality easier.
14def4f to
5d80f0b
Compare
suutari-ai
reviewed
Nov 15, 2018
| 'irene.archer@x3d2e92ec.sanitized.net') | ||
| assert user.sanitize_email(' test3@example.com ') == ( | ||
| 'irene.archer@x3d2e92ec.sanitized.net') | ||
| assert user.sanitize_email('test<@example.net') == ( |
Member
There was a problem hiding this comment.
Why did you add < to this email?
TLD `.invalid` is quaranteed to be invalid by IETF RFC2606 hence it is safer than earlier `sanitized.net`, that could, in theory, have e.g. a working mail server.
5d80f0b to
cb1cea6
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
TLD
.invalidis quaranteed to be invalid by IETF RFC2606 hence it is safer than earliersanitized.net, that could, in theory, have e.g. a working mail server.