doc / ch.tutteli.atrium.api.infix.en_GB / containsNot

containsNot

infix fun <T : CharSequence> Expect<T>.containsNot(o: o): NotCheckerOption<T, NotSearchBehaviour> (source)

Creates a CharSequenceContains.Builder based on this Expect which allows to define more sophisticated contains not assertion.

Parameters

o - The filler object o.

Return
The newly created builder.

infix fun <T : CharSequence> Expect<T>.containsNot(expected: CharSequenceOrNumberOrChar): Expect<T> (source)

Expects that the subject of the assertion (a CharSequence) does not contain expected's toString representation.

It is a shortcut for contains not value expected.

Notice that a runtime check applies which assures that only CharSequence, Number and Char are passed (this function expects CharSequenceOrNumberOrChar (which is a typealias for Any for your convenience, so that you can mix String and Int for instance).

Exceptions

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

Return
This assertion container to support a fluent API.

infix fun <T : CharSequence> Expect<T>.containsNot(values: Values<CharSequenceOrNumberOrChar>): Expect<T> (source)

Expects that the subject of the assertion (a CharSequence) does not contain the toString representation of the given values.

It is a shortcut for contains not the values(expected, *otherExpected).

Notice that a runtime check applies which assures that only CharSequence, Number and Char are passed (this function expects CharSequenceOrNumberOrChar (which is a typealias for Any for your convenience, so that you can mix String and Int for instance).

Parameters

values - The values which should not be found -- use the function values(t, ...) to create a Values.

Exceptions

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

Return
This assertion container to support a fluent API.

infix fun <E, T : Iterable<E>> Expect<T>.containsNot(expected: E): Expect<T> (source)

Expects that the subject of the assertion (an Iterable) does not contain the expected value.

It is a shortcut for containsNot o value expected

Exceptions

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

Return
An Expect for the current subject of the assertion.

infix fun <E, T : Iterable<E>> Expect<T>.containsNot(values: Values<E>): Expect<T> (source)

Expects that the subject of the assertion (an Iterable) does not contain the expected values.

It is a shortcut for containsNot o the values(...)

Parameters

values - The values which should not be contained within the Iterable -- use the function values(t, ...) to create a Values.

Exceptions

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

Return
An Expect for the current subject of the assertion.