junit4git icon indicating copy to clipboard operation
junit4git copied to clipboard

Getting error "Listener of type 'MismatchReportingTestListener' has already been added and not removed."

Open SureshG02 opened this issue 4 years ago • 1 comments

I'm exploring this plugin but seems many of test cases in my project got failed with below error. I'm using @RunWith(MockitoJUnitRunner.class) in almost all of my test cases. Do you know what step I'm missing here?

Problems adding Mockito listener.
Listener of type 'MismatchReportingTestListener' has already been added and not removed.
It indicates that previous listener was not removed according to the API.
When you add a listener, don't forget to remove the listener afterwards:
  Mockito.framework().removeListener(myListener);
For more information, see the javadoc for RedundantListenerException class.

SureshG02 avatar Dec 17 '20 14:12 SureshG02

Thanks for reporting this issue. The short answer is no. Are you using Maven or Gradle? Could you share a hello world project that reproduces the issue?

rpau avatar Dec 27 '20 10:12 rpau