Package org.junit.internal.runners.rules
Class RuleMemberValidator
- java.lang.Object
-
- org.junit.internal.runners.rules.RuleMemberValidator
-
public class RuleMemberValidator extends java.lang.ObjectA RuleMemberValidator validates the rule fields/methods of aTestClass. All reasons for rejecting theTestClassare written to a list of errors.There are four slightly different validators. The
CLASS_RULE_VALIDATORvalidates fields with aClassRuleannotation and theRULE_VALIDATORvalidates fields with aRuleannotation.The
CLASS_RULE_METHOD_VALIDATORvalidates methods with aClassRuleannotation and theRULE_METHOD_VALIDATORvalidates methods with aRuleannotation.
-
-
Field Summary
Fields Modifier and Type Field Description static RuleMemberValidatorCLASS_RULE_METHOD_VALIDATORValidates methods with aClassRuleannotation.static RuleMemberValidatorCLASS_RULE_VALIDATORValidates fields with aClassRuleannotation.static RuleMemberValidatorRULE_METHOD_VALIDATORValidates methods with aRuleannotation.static RuleMemberValidatorRULE_VALIDATORValidates fields with aRuleannotation.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidvalidate(TestClass target, java.util.List<java.lang.Throwable> errors)Validate theTestClassand adds reasons for rejecting the class to a list of errors.
-
-
-
Field Detail
-
CLASS_RULE_VALIDATOR
public static final RuleMemberValidator CLASS_RULE_VALIDATOR
Validates fields with aClassRuleannotation.
-
RULE_VALIDATOR
public static final RuleMemberValidator RULE_VALIDATOR
Validates fields with aRuleannotation.
-
CLASS_RULE_METHOD_VALIDATOR
public static final RuleMemberValidator CLASS_RULE_METHOD_VALIDATOR
Validates methods with aClassRuleannotation.
-
RULE_METHOD_VALIDATOR
public static final RuleMemberValidator RULE_METHOD_VALIDATOR
Validates methods with aRuleannotation.
-
-