Annotation Type SuppressStaticInitializationFor
@Target({TYPE,METHOD})
@Retention(RUNTIME)
@Documented
@Inherited
public @interface SuppressStaticInitializationFor
Use this annotation to suppress static initializers (constructors) for one or
more classes.
The reason why an annotation is needed for this is because we need to know at load-time if the static constructor execution for this class should be skipped or not. Unfortunately we cannot pass the class as the value parameter to the annotation (and thus get type-safe values) because then the class would be loaded before PowerMock could have suppressed its constructor.
-
Optional Element Summary
Optional Elements
-
Element Details
-
value
String[] value- Default:
{""}
-