Test your code

Code review flavors

I have seen lots of people who are doing code reviews and others who think it's just waste of time or they are not convinced about it. The latter are probably defensive and don't want for others to tell them how good or bad is their code. And most probably they don't write any kind… Continue reading Code review flavors

Advertisements
Test your code

Are you verifying your stubs?

What is stubbing? What is verifying? Do we need both? If we look into the java docs for Mockito.when() (stubbing) and Mockito.verify() (verifying behavior) we see something strange that is common to both: Although it is possible to verify a stubbed invocation, usually it's just redundant. Well, we known that the difference between stubs and… Continue reading Are you verifying your stubs?