Class NoShadowingOrOverridesOnMethodsRule
java.lang.Object
com.carrotsearch.randomizedtesting.rules.NoShadowingOrOverridesOnMethodsRule
- All Implemented Interfaces:
org.junit.rules.TestRule
- Direct Known Subclasses:
NoClassHooksShadowingRule
,NoInstanceHooksOverridesRule
public abstract class NoShadowingOrOverridesOnMethodsRule
extends Object
implements org.junit.rules.TestRule
Discovers shadowing or override relationships among methods annotated with any of the
provided annotations.
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionNoShadowingOrOverridesOnMethodsRule
(Class<? extends Annotation>... annotations) -
Method Summary
Modifier and TypeMethodDescriptionfinal org.junit.runners.model.Statement
apply
(org.junit.runners.model.Statement base, org.junit.runner.Description description) private void
checkNoShadowsOrOverrides
(Class<?> clazz, ClassModel classModel, Class<? extends Annotation> ann) private String
final void
protected boolean
-
Field Details
-
annotations
-
-
Constructor Details
-
NoShadowingOrOverridesOnMethodsRule
-
-
Method Details
-
apply
public final org.junit.runners.model.Statement apply(org.junit.runners.model.Statement base, org.junit.runner.Description description) - Specified by:
apply
in interfaceorg.junit.rules.TestRule
-
validate
- Throws:
Throwable
-
checkNoShadowsOrOverrides
private void checkNoShadowsOrOverrides(Class<?> clazz, ClassModel classModel, Class<? extends Annotation> ann) -
verify
-
signature
-