TagMockito

No more development, TDD begins with MoreUnit

N

Do you program or do you already TDD? 🙂
If you prefer to do TDD you will love the eclipse plug-in called MoreUnit. It is as simple as powerful. All it does is executing tests from corresponding productive class and makes it very simple to change between them.
Just press Ctrl-J (like Jump) to jump from test to implementing class and the other way. Or press Ctrl-R (like Run) to run the test regardless if you are in the test or the implementation class.

Mockito – ArgumentMatcher vs ArgumentCaptor

M

Since a few weeks the new mockito release candidate is available. So I think it is the right time to place a new post. Here I will show the differences between ArgumentMatcher and ArgumentCaptor. Most developer will first see the ArgumentMatcher and use it. What can be done with ArgumentCaptor is often not seen. With the sample I will show that an ArgumentMatcher should not be used to fetch arguments. For this work there is the ArgumentCaptor. The Matcher should really be used to check if an...

Create mocks with mockito

C

This is a small summarization what the differences are between the different variations creating mocks with mockito. Null values (default) Per default, after creating a mock, every method will return null. Just create your mock with: I think, this is very useful and straight forward. (And based by mockito developers idea, to create very fast a mock for testing). Sometimes it is very difficult to determine an error which was produced through such a null value. For this case it is very...

Mockito

M

A few weeks ago, I started using Mockito. Mockito is a mocking framework for Java.
What mockito is able to do:
– mocking interfaces and abstract classes
– mocking concrete classes
– spy real objects
()
I liked mockito so much that I decided to present it to you…

Recent Posts