Package com.google.common.truth
Class IntegerSubject
java.lang.Object
com.google.common.truth.Subject<IntegerSubject,Integer>
com.google.common.truth.ComparableSubject<IntegerSubject,Integer>
com.google.common.truth.IntegerSubject
Propositions for
Integer subjects.-
Nested Class Summary
Nested classes/interfaces inherited from class com.google.common.truth.Subject
Subject.HasField -
Field Summary
FieldsFields inherited from class com.google.common.truth.Subject
failureStrategy -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidis(byte other) voidis(long other) voidis(short other) voidisBetween(int lower, int upper) Deprecated.UseisIn(Range.open(lower, upper))instead.voidisEqualTo(long other) voidFails if the subject is not equal to the given object.voidisInclusivelyInRange(int lower, int upper) Deprecated.UseisIn(Range.closed(lower, upper))instead.voidisNotEqualTo(Object other) Fails if the subject is equal to the given object.Methods inherited from class com.google.common.truth.ComparableSubject
comparesEqualTo, isAtLeast, isAtMost, isGreaterThan, isIn, isLessThan, isNotInMethods inherited from class com.google.common.truth.Subject
check, equals, fail, fail, fail, failWithBadResults, failWithCustomSubject, failWithoutSubject, failWithRawMessage, getDisplaySubject, getSubject, hasField, hashCode, internalCustomName, is, isA, isInstanceOf, isNotA, isNotInstanceOf, isNotNull, isNotSameAs, isNull, isSameAs, labeled, named
-
Field Details
-
INTEGER
Deprecated.Use afor eachstyle loop over yourIterable<Integer>instead.
-
-
Constructor Details
-
IntegerSubject
-
-
Method Details
-
isInclusivelyInRange
Deprecated.UseisIn(Range.closed(lower, upper))instead.Attests that the int is inclusively within thelowerandupperbounds provided or fails. -
isBetween
Deprecated.UseisIn(Range.open(lower, upper))instead.Attests that the int is exclusively within thelowerandupperbounds provided or fails. -
isEqualTo
Description copied from class:SubjectFails if the subject is not equal to the given object.- Overrides:
isEqualToin classSubject<IntegerSubject,Integer>
-
isNotEqualTo
Description copied from class:SubjectFails if the subject is equal to the given object.- Overrides:
isNotEqualToin classSubject<IntegerSubject,Integer>
-
isEqualTo
public void isEqualTo(long other) -
is
public void is(long other) -
is
public void is(short other) -
is
public void is(byte other)
-
for eachstyle loop over yourIterable<Integer>instead.