Package com.google.common.truth
Class ClassSubject
- java.lang.Object
-
- com.google.common.truth.Subject<ClassSubject,java.lang.Class<?>>
-
- com.google.common.truth.ClassSubject
-
public class ClassSubject extends Subject<ClassSubject,java.lang.Class<?>>
Propositions forClasssubjects.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class com.google.common.truth.Subject
Subject.HasField
-
-
Field Summary
-
Fields inherited from class com.google.common.truth.Subject
failureStrategy
-
-
Constructor Summary
Constructors Constructor Description ClassSubject(FailureStrategy failureStrategy, java.lang.Class<?> o)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voiddeclaresField(java.lang.String fieldName)voidisAssignableFrom(java.lang.Class<?> clazz)Fails if this class or interface is not the same as or a superclass or superinterface of the given class or interface.voidisAssignableTo(java.lang.Class<?> clazz)Fails if this class or interface is not the same as or a subclass or subinterface of, the given class or interface.-
Methods inherited from class com.google.common.truth.Subject
check, equals, fail, fail, fail, failWithBadResults, failWithCustomSubject, failWithoutSubject, failWithRawMessage, getDisplaySubject, getSubject, hasField, hashCode, internalCustomName, is, isA, isEqualTo, isInstanceOf, isNotA, isNotEqualTo, isNotInstanceOf, isNotNull, isNotSameAs, isNull, isSameAs, labeled, named
-
-
-
-
Constructor Detail
-
ClassSubject
ClassSubject(FailureStrategy failureStrategy, java.lang.Class<?> o)
-
-
Method Detail
-
isAssignableFrom
@GwtIncompatible("isAssignableFrom") public void isAssignableFrom(java.lang.Class<?> clazz)Fails if this class or interface is not the same as or a superclass or superinterface of the given class or interface.
-
isAssignableTo
@GwtIncompatible("isAssignableFrom") public void isAssignableTo(java.lang.Class<?> clazz)Fails if this class or interface is not the same as or a subclass or subinterface of, the given class or interface.
-
declaresField
@GwtIncompatible("Reflection") public void declaresField(java.lang.String fieldName)
-
-