- notNull
Assert that an object is not null .Assert.notNull(clazz, "The class must not be null");
- hasText
Assert that the given String has valid text content; that is, it must not be
null and must contain
- isInstanceOf
Assert that the provided object is an instance of the provided class.Assert.instanceOf(Foo.class, fo
- isTrue
Assert a boolean expression, throwing IllegalArgumentException if the test
result is false.Assert.is
- notEmpty
Assert that an array has elements; that is, it must not benull and must have at
least one element.As
- state
Assert a boolean expression, throwing IllegalStateException if the test result
is false. Call isTrue
- doesNotContain
Assert that the given text does not contain the given substring.Assert.doesNotContain(name, "rod", "
- hasLength
Assert that the given String is not empty; that is, it must not be null and not
the empty String.Ass
- isAssignable
Assert that superType.isAssignableFrom(subType) is true.Assert.isAssignable(Number.class, myClass);
- noNullElements
Assert that an array has no null elements. Note: Does not complain if the array
is empty!Assert.noNu