doc / ch.tutteli.atrium.api.fluent.en_GB / isNotEmpty

isNotEmpty

fun <T : CharSequence> Expect<T>.isNotEmpty(): Expect<T> (source)

Expects that the subject of this expectation (a CharSequence) CharSequence.kotlin.text.isNotEmpty.

expect("XYZ").isNotEmpty()

fails {
    expect("").isNotEmpty()
}

// use isNotBlank to check for whitespaces
expect(" ").isNotEmpty()

Return
an Expect for the subject of this expectation.