public class VerboseMockitoJUnitRunner
extends org.junit.runner.Runner
implements org.junit.runner.manipulation.Filterable
This runner does exactly what MockitoJUnitRunner
does but also
adds extra Mocktio hints to the exception message.
The point is that Mockito should help the tdd developer to quickly figure out if the test fails for the right reason and track the reason.
The implemntation is pretty hacky - it uses brute force of reflection to modify the exception message and add extra mockito hints. You've been warned.
Do you think it is useful or not? Drop us an email at mockito@googlegroups.com
Experimental implementation - will change in future!
Constructor and Description |
---|
VerboseMockitoJUnitRunner(Class<?> klass) |
Modifier and Type | Method and Description |
---|---|
void |
filter(org.junit.runner.manipulation.Filter filter) |
org.junit.runner.Description |
getDescription() |
void |
run(org.junit.runner.notification.RunNotifier notifier) |
public VerboseMockitoJUnitRunner(Class<?> klass) throws InvocationTargetException
InvocationTargetException
public void run(org.junit.runner.notification.RunNotifier notifier)
run
in class org.junit.runner.Runner
public org.junit.runner.Description getDescription()
getDescription
in interface org.junit.runner.Describable
getDescription
in class org.junit.runner.Runner
public void filter(org.junit.runner.manipulation.Filter filter) throws org.junit.runner.manipulation.NoTestsRemainException
filter
in interface org.junit.runner.manipulation.Filterable
org.junit.runner.manipulation.NoTestsRemainException
Copyright © 2018. All rights reserved.