doc / ch.tutteli.atrium.api.cc.infix.en_GB / notToBe

notToBe

infix fun <T : Any> Assert<T>.notToBe(expected: T): AssertionPlant<T>
Deprecated: Switch from Assert to Expect; will be removed with 1.0.0 -- see https://github.com/robstoll/atrium/releases/tag/v0.12.0#migration for migration hints and scripts.

Makes the assertion that the Assert.subject is not (equal to) expected.

This method might enforce in the future, that expected has to be the same type as Assert.subject. Currently the following is possible: assert(1).notToBe(1.0)

Exceptions

AssertionError - Might throw an AssertionError if the assertion made is not correct.

Return
This plant to support a fluent API.

infix fun <T : Any> Assert<T>.notToBe(keyword: Keyword): Nothing
Deprecated: This call will most probably fail at runtime because the given subject is not a collection as you might have assumed. If you really want to compare the subject against the keyword, then cast the keyword to Any

infix fun <T : CharSequence> Assert<T>.notToBe(Empty: Empty): AssertionPlant<T>
Deprecated: Switch from Assert to Expect; will be removed with 1.0.0 -- see https://github.com/robstoll/atrium/releases/tag/v0.12.0#migration for migration hints and scripts.

Makes the assertion that the Assert.subject CharSequence.kotlin.text.isNotEmpty.

Parameters

Empty - Has to be Empty.

Exceptions

AssertionError - Might throw an AssertionError if the assertion made is not correct.

Return
This plant to support a fluent API.

infix fun <T : CharSequence> Assert<T>.notToBe(Blank: Blank): AssertionPlant<T>
Deprecated: Switch from Assert to Expect; will be removed with 1.0.0 -- see https://github.com/robstoll/atrium/releases/tag/v0.12.0#migration for migration hints and scripts.

Makes the assertion that the Assert.subject CharSequence.kotlin.text.isNotBlank.

Parameters

Blank - Has to be Blank.

Exceptions

AssertionError - Might throw an AssertionError if the assertion made is not correct.

Return
This plant to support a fluent API.