Details
-
Type:
Bug
-
Status:
Resolved
-
Priority:
Major
-
Resolution: Fixed
-
Affects Version/s: FEST-Assert 1.2
-
Fix Version/s: FEST-Assert 1.3
-
Component/s: Assert
-
Labels:None
-
Number of attachments :
Description
I would like to assert that Integer instance is null. This however needs nasty workaround:
Integer i = null; assertThat(i).isNull(); //does not compile assertThat((Object)i).isNull();
This is because Assertions#assertThat taking Integer instance does automatic unboxing and returns org.fest.assertions.IntAssert instance, that inherits from org.fest.assertions.PrimitiveAssert rather than returning org.fest.assertions.GenericAssert.
FEST-133is the same problem for double.It's best to implement the solution to this problem for all primitive types in one go, and the progress thereof will be tracked by
FEST-133.