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
Add asBoolean|Byte|Short|Int|Long|Float|Double
to String
assertions
#2580
Conversation
Hi @scordio, sorry for bothering. This PR implements the methods you mentioned, could you please review the code? |
Hi @hezean, thanks for the PR. Despite my proposal at #2509 (comment), we haven't discussed these new methods in the team yet, so it may take some time before we move on to the review phase. Thanks in advance for your patience! |
Hi @scordio, it seems that 3.24.2 is already released. Any update on the methods related in this pr?
|
Hi @hezean , thanks again for your patience. I'll make sure this gets covered for 3.25.0. |
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.
Thanks @hezean, first round of code review done. Sorry for the long wait!
assertj-core/src/main/java/org/assertj/core/api/AbstractStringAssert.java
Outdated
Show resolved
Hide resolved
assertj-core/src/main/java/org/assertj/core/api/AbstractStringAssert.java
Outdated
Show resolved
Hide resolved
assertj-core/src/main/java/org/assertj/core/api/AbstractStringAssert.java
Outdated
Show resolved
Hide resolved
assertj-core/src/main/java/org/assertj/core/api/AbstractStringAssert.java
Outdated
Show resolved
Hide resolved
assertj-core/src/main/java/org/assertj/core/api/AbstractStringAssert.java
Outdated
Show resolved
Hide resolved
assertj-core/src/main/java/org/assertj/core/api/AbstractStringAssert.java
Outdated
Show resolved
Hide resolved
assertj-core/src/test/java/org/assertj/core/api/string_/StringAssert_asBoolean_Test.java
Outdated
Show resolved
Hide resolved
assertj-core/src/test/java/org/assertj/core/api/string_/StringAssert_asBoolean_Test.java
Outdated
Show resolved
Hide resolved
assertj-core/src/test/java/org/assertj/core/api/string_/StringAssert_asByte_Test.java
Show resolved
Hide resolved
Co-Authored-By: Matthew <77274680+MatthewLENG2002@users.noreply.github.com>
Hi @joel-costigliola, I really appreciate for your review, and thanks for giving me an opportunity to contribute to assertj! I've just cleaned up this PR, fixing all the issues you pointed out. Please let me know if anything should be made better. |
Integrated thanks @hezean! I did some minor cleanup and added support for soft assertions which is a bit tricky to do if you are not familiar with how they work, you can look at the commit if you are interested, anyway you get full credit for the changes 😉 |
As #2509 (comment) mentioned, several methods are added as the shortcuts for
extracting
boolean and numbers.Check List: