-
Notifications
You must be signed in to change notification settings - Fork 171
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
For #1462: Introduce text.Mapped #1485
Conversation
@0crat status |
@victornoel This is what I know about this job in C63314D6Z, as in §32:
|
@fabriciofx Please take a look |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@andreoss Please, take a look in my comments.
* | ||
* @since 0.47 | ||
*/ | ||
final class MappedTest { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@andreoss please, add a #equals()
test.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@fabriciofx Why do you think Mapped
should preserve equality?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@andreoss Some code like it new Mapped(String::toLowercase, new TextOf("ABC").equals("abc")
is valid? If yes, then Mapped
should preserve equality, right?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@fabriciofx In order to do that, it has to extend TextEnvelope
and use TextOf
. Both seem to be unnecessary for this task.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@andreoss Ok, thanks for this information!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@andreoss @fabriciofx actually all texts implementation should either implement equals themselves or indeed delegate to an implementation of text that does. So I think we need to do it either way here yes. Same with tostring and hashcode. You can add a todo if you want.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@victornoel Done. It uses TextOf
now.
Codecov Report
@@ Coverage Diff @@
## master #1485 +/- ##
============================================
+ Coverage 89.40% 89.44% +0.04%
- Complexity 1632 1639 +7
============================================
Files 278 281 +3
Lines 3906 3914 +8
Branches 210 208 -2
============================================
+ Hits 3492 3501 +9
+ Misses 382 381 -1
Partials 32 32
Continue to review full report at Codecov.
|
@0crat status |
@victornoel This is what I know about this job in C63314D6Z, as in §32:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@andreoss It seems fine to me. @victornoel WDYT? Can you merge it?
* | ||
* @since 0.47 | ||
*/ | ||
final class MappedTest { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@andreoss Ok, thanks for this information!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@andreoss see the one comment
@victornoel |
@andreoss great! |
@rultor merge |
@victornoel OK, I'll try to merge now. You can check the progress of the merge here |
@victornoel Done! FYI, the full log is here (took me 12min) |
@fabriciofx/z resigned from #1485, since the job is not in scope anymore |
Per #1462
text.Mapped