public final class OptionalLongSubject extends Subject<OptionalLongSubject,OptionalLong>
OptionalLong
subjects.Modifier and Type | Method and Description |
---|---|
void |
hasValue(long expected)
Fails if the
OptionalLong does not have the given value or the subject is null. |
LongSubject |
hasValueThat()
Prepares for a check regarding the value contained within the
OptionalLong . |
void |
isEmpty()
Fails if the
OptionalLong is present or the subject is null. |
void |
isPresent()
Fails if the
OptionalLong is empty or the subject is null. |
static Subject.Factory<OptionalLongSubject,OptionalLong> |
optionalLongs() |
actual, actualAsString, actualCustomStringRepresentation, check, check, equals, fail, fail, fail, failComparing, failComparing, failWithActual, failWithActual, failWithBadResults, failWithCustomSubject, failWithoutActual, failWithoutActual, failWithoutSubject, failWithRawMessage, failWithRawMessageAndCause, getSubject, hashCode, ignoreCheck, internalCustomName, isAnyOf, isEqualTo, isIn, isInstanceOf, isNoneOf, isNotEqualTo, isNotIn, isNotInstanceOf, isNotNull, isNotSameAs, isNull, isSameAs, named, toString
public void isPresent()
OptionalLong
is empty or the subject is null.public void isEmpty()
OptionalLong
is present or the subject is null.public void hasValue(long expected)
OptionalLong
does not have the given value or the subject is null. More
sophisticated comparisons can be done using hasValueThat()
.public LongSubject hasValueThat()
OptionalLong
. Fails
immediately if the subject is empty.public static Subject.Factory<OptionalLongSubject,OptionalLong> optionalLongs()
Copyright © 2018. All rights reserved.