Package org.mockito.exceptions.misusing
Class RedundantListenerException
- java.lang.Object
-
- java.lang.Throwable
-
- java.lang.Exception
-
- java.lang.RuntimeException
-
- org.mockito.exceptions.base.MockitoException
-
- org.mockito.exceptions.misusing.RedundantListenerException
-
- All Implemented Interfaces:
Serializable
public class RedundantListenerException extends MockitoException
Reported when instance ofMockitoListener
is being added to Mockito (seeMockitoFramework
) and there is already a listener with this implementation type registered. Note that it is ok to add multiple different implementations of the same listener interface type.Indicates a user error - previous listener was not removed according to the API specification - see
MockitoFramework.addListener(MockitoListener)
.- Since:
- 2.5.2
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description RedundantListenerException(String message)
-
Method Summary
-
Methods inherited from class org.mockito.exceptions.base.MockitoException
getUnfilteredStackTrace
-
Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
-
-
-
Constructor Detail
-
RedundantListenerException
public RedundantListenerException(String message)
-
-