Make String to Boolean parameter conversion more strict#3178
Make String to Boolean parameter conversion more strict#3178marcphilipp merged 6 commits intojunit-team:mainfrom s-rwe:issues/3177
Conversation
Cause use of anything other than 'true' or 'false' (case-insensitive) fail in conversion, to make potential typos explicitly visible (instead of implicitly just treating all else as 'false') Includes a few tests for failures on invalid values, for conversions handled by StringToBooleanAndCharPrimitiveConverter. Issue: #3177
sbrannen
left a comment
There was a problem hiding this comment.
Thanks for submitting the PR so quickly!
I requested a few minor changes.
Sure thing, likewise thanks for the quick review :) Requested changes pushed accordingly. |
There was a problem hiding this comment.
The proposal looks good to me from a technical standpoint.
All that's missing is an entry in the release notes and, potentially, a note in the user guide.
Though I think we should hold off on those last two tasks until the rest of the team has voiced their approval.
|
Team Decision: Make it more strict by default since it's a more sane behavior. |
|
@s-rwe Could you please add an entry to the release notes and update the table in the User Guide? |
Ok sure thanks, done accordingly. |
|
I'll take it from here. |
|
@s-rwe Thank you for you contribution! 🙇♂️ |
Cause use of anything other than 'true' or 'false' (case-insensitive) fail in conversion, to make potential typos explicitly visible (instead of implicitly just treating all else as 'false')
Includes a few tests for failures on invalid values, for conversions handled by
StringToBooleanAndCharPrimitiveConverter.Issue: #3177
I hereby agree to the terms of the JUnit Contributor License Agreement.
Definition of Done
@APIannotations