We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
This is a refined feature request derived from #2509. Per @scordio's commented, it might be reasonable to add following signatures.
AbstractStringAssert#asBoolean() returns BooleanAssert AbstractStringAssert#asByte() returns ByteAssert AbstractStringAssert#asByte(int radix) returns ByteAssert AbstractStringAssert#asShort() returns ShortAssert AbstractStringAssert#asShort(int radix) returns ShortAssert AbstractStringAssert#asInteger() returns IntegerAssert AbstractStringAssert#asInteger(int radix) returns IntegerAssert AbstractStringAssert#asLong() returns LongAssert AbstractStringAssert#asLong(int radix) returns LongAssert AbstractStringAssert#asFloat() returns FloatAssert AbstractStringAssert#asDouble() returns DoubleAssert
NumberFormatException throwable from those parse...(String) methods, except the Boolean#parseBoolean, should be regarded as failing assertions.
NumberFormatException
parse...(String)
Boolean#parseBoolean
assertThat("yes") // .isNotNull() // implicit .asBoolean() .isTrue(); // fails assertThat("32") .asInteger() .isEqualTo(32); // succeeds assertThat(".0d") .asDouble() .isZero();
The text was updated successfully, but these errors were encountered:
Hi, I am interested in this. If these modifications are considered necessary, can you assign me?
Sorry, something went wrong.
asBoolean|Byte|Short|Int|Long|Float|Double
String
Tentatively slated for 3.24.0 solely for the purpose of team discussion, keeping #2580 on hold.
We are agreeing to this as it is limited to string assertions
Addressed by #2580
joel-costigliola
Successfully merging a pull request may close this issue.
Summary
This is a refined feature request derived from #2509.
Per @scordio's commented, it might be reasonable to add following signatures.
NumberFormatException
throwable from thoseparse...(String)
methods, except theBoolean#parseBoolean
, should be regarded as failing assertions.Example
The text was updated successfully, but these errors were encountered: