fun <T : Collection<*>> Expect<T>.hasSize(expected: Int): Expect<T>
Expects that the subject of the assertion (a Collection) has the given expected size.
Shortcut for expected.toBe(expectedSize)
.
AssertionError
- Might throw an AssertionError if the assertion made is not correct.
Return
This assertion container to support a fluent API.