This blog post is outdated! If you want to learn how you can write unit tests for Spring MVC controllers, you should take a look at my updated Spring MVC Test tutorial. It describes how you can write unit tests for Spring MVC controllers with JUnit 5. The first part of this tutorial described how […] Read more
Unit Testing
Adding integration tests to a Maven build has traditionally been a bit painful. I suspect that the reason for this is that the standard directory layout has only one test directory (src/test). If we want to use the standard directory layout and add integration tests to our Maven build, we have two options: First, we […] Read more
Continuous integration has established its place among the good software development practices. However, setting up a continuous integration server and configuring it to run your tests automatically does not mean that you are really doing continuous integration. It only means that you have installed a continuous integration server and it run your tests automatically. Martin […] Read more
A common method of setting transaction boundaries in Spring Framework is to use its annotation driven transaction management and annotate service methods with @Transactional annotation. Seems pretty simple, right? Yes and no. Even though the annotation driven transaction management of Spring Framework is easy to setup and use, there are a few things which you […] Read more
Apache Wicket is a component based web application framework which offers good unit testing capabilities. This blog entry describes how you can use those capabilities to mock beans which are injected by using the Spring integration of Apache Wicket (Note: The precondition of this blog entry is that you are using Apache Wicket 1.5). The […] Read more
Automatic testing and continuous integration have become a some what standard in modern day software development. Even though I have noticed by experience that automatic testing does indeed reduce the number of bugs found from the software, not everyone is fond of writing unit tests. This blog post gathers together some of the objections against […] Read more