A Java toolkit for automated developer testing.
Ranked in these QuestionsQuestion Ranking
Pros
Pro Can mock everything
JMockit has the ability to mock final classes and final, private and static methods whereas other mocking frameworks only work on a few of these.
Pro Instance capture ability
Being able to capture instances and mock implementations as the test executes without having any knowledge of the actual implementation classes allows JMockit to verify these special objects through regular assertions with custom validation methods for each matching object.
Pro Great resources
The official tutorial contains thorough explanations and discussions of all methods, annotations, fields etc.., with lots of easy to understand examples.
The API documentation is very complete as well and it provides detailed explanation for all elements of the mocking API.
Cons
Con Its development is abandoned
No new commits for several years.
Con Small community support
Only 3 contributors on Github , near all work done by 1 developer.
Con Learning curve is a bit steep
Since JMockit has a much larger scope that other mocking frameworks and as a result, the learning curve will be a bit steep.