Increased test coverage based on Sonar.

please use hamcrest matchers where you can. they give us much more useful output when they fail.