doc / ch.tutteli.atrium.creating / IBaseAssertionPlant

IBaseAssertionPlant

interface IBaseAssertionPlant<out T, out A : IBaseAssertionPlant<T, A>>

Represents a plant for IAssertions and offers methods to create and to add assertions to this plant.

It defines what IAssertionPlant and IAssertionPlantNullable have in common but is typically not used as entry point for assertion functions (with a few exceptions like equality and identity assertions). Most of the time you want to define an assertion function for IAssertionPlant.

Parameters

T - The type of the subject of this IAssertionPlant. A - A subtype of IBaseAssertionPlant which is used in the fluent style API.

Properties

subject

abstract val subject: T

The subject for which this plant will create IAssertions.

Functions

addAssertion

abstract fun addAssertion(assertion: IAssertion): A

Adds the given assertion to this plant.

Inheritors

IAssertionPlant

interface IAssertionPlant<out T : Any> : IBaseAssertionPlant<T, IAssertionPlant<T>>

Represents a plant for IAssertions based on a non nullable subject.

IAssertionPlantNullable

interface IAssertionPlantNullable<out T> : IBaseAssertionPlant<T, IAssertionPlantNullable<T>>

Represents an assertion plant for nullable types.

IBaseReportingAssertionPlant

interface IBaseReportingAssertionPlant<out T, out A : IBaseAssertionPlant<T, A>> : IBaseAssertionPlant<T, A>, IAssertionPlantWithCommonFields<T>