abstract fun createDescriptiveWithFailureHint(description: Translatable, representation: Any, test: () -> Boolean, showHint: () -> Boolean, failureHintFactory: () -> Assertion): Assertion
Shall create kind of a DescriptiveAssertion if test holds or an AssertionGroup which includes additionally
a failure hint created by the given failureHintFactory in case showHint evaluates to true
.
Notice, it is up to the implementation if a really a DescriptiveAssertion is created if test holds or if another kind of Assertion is used. However, the implementation should treat the given description and representation as it would be treated if it is part of a DescriptiveAssertion.
description
- The DescriptiveAssertion.description.
representation
- The DescriptiveAssertion.representation.
test
- The test which should be used for DescriptiveAssertion.holds.
showHint
- Indicates whether the failure hint shall be shown in case test fails.
failureHintFactory
- A factory method used to create the failure hint.