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

getExisting

infix fun <K, V : Any, T : Map<out K, V>> Assert<T>.getExisting(key: K): Assert<V>
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 contains the given key, creates a feature assertion plant for the corresponding value and returns the newly created plant.

Exceptions

AssertionError - Might throw an AssertionError if the given key does not exist.

Return
The newly created plant for the feature

infix fun <K, V : Any, T : Map<out K, V>> Assert<T>.getExisting(key: Key<K>): MapGetOption<K, V, 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.

Prepares the assertion about the return value of calling get with the given key.

Return
A fluent builder to finish the assertion.