JMockTestWithoutRunWithOrRuleAnnotation
jMock tests must have a @RunWith(JMock.class) annotation, or the Mockery field must have a @Rule JUnit annotation

Category
JMOCK
Severity
ERROR
Maturity

The problem

jMock tests must have a @RunWith(JMock.class) annotation, or the Mockery field must have a @Rule JUnit annotation. If this is not done, then all of your jMock tests will run and pass, but none of your assertions will actually be evaluated. Your tests will pass even if they shouldn’t.

Suppression

Suppress false positives by adding an @SuppressWarnings("JMockTestWithoutRunWithOrRuleAnnotation") annotation to the enclosing element.