Package com.google.common.truth
Class AbstractVerb<T extends AbstractVerb<T>>
java.lang.Object
com.google.common.truth.AbstractVerb<T>
- Direct Known Subclasses:
TestVerb
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic class
A special Verb implementation which wraps a SubjectFactoryprotected static class
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription<S extends Subject<S,
T>, T, SF extends SubjectFactory<S, T>>
AbstractVerb.DelegatedVerb<S,T> about
(SF factory) The recommended method of extension of Truth to new types, which is documented incom.google.common.truth.delegation.DelegationTest
.void
fail()
Triggers the failure strategy with an empty failure messagevoid
Triggers the failure strategy with the given failure messageprotected abstract String
protected FailureStrategy
<T> IteratingVerb<T>
abstract T
withFailureMessage
(String failureMessage) Overrides the failure message of the subsequent subject's propositions.
-
Field Details
-
failureStrategy
-
-
Constructor Details
-
AbstractVerb
-
-
Method Details
-
getFailureStrategy
-
fail
public void fail()Triggers the failure strategy with an empty failure message -
fail
Triggers the failure strategy with the given failure message -
withFailureMessage
Overrides the failure message of the subsequent subject's propositions.- Parameters:
factory
- a SubjectFactory<S, T> implementation- See Also:
-
com.google.common.truth.delegation.DelegationTest
-
getFailureMessage
-
about
public <S extends Subject<S,T>, AbstractVerb.DelegatedVerb<S,T, SF extends SubjectFactory<S, T>> T> about(SF factory) The recommended method of extension of Truth to new types, which is documented incom.google.common.truth.delegation.DelegationTest
.- Parameters:
factory
- a SubjectFactory<S, T> implementation- See Also:
-
com.google.common.truth.delegation.DelegationTest
-
in
@GwtIncompatible("com.google.common.truth.IteratingVerb") public <T> IteratingVerb<T> in(Iterable<T> data)
-