I'm not quite sure if I'm missing something really obvious here but my searches on this topic aren't returning results of use to me. I have recently gotten more into unit testing and using mock objects. This is all well and good for testing objects in isolation but, in a complex Spring MVC application that is interacting through AJAX with a lot of Javascript code I sometimes run into issues such as a value being passed in that is not what it needs to be and causes something to break. Of course it still fulfills the type, such as being a String, but it may be null, which would cause something to break down the line.I'm not quite sure if I'm missing something rea