Related questions
EasyMock: Void Methods
I have a method that returns void in a class that is a dependency of the class I want to test.
This class is huge and I'm only using this single method from it.
I need to replace the implementation …
How to mock the HttpServletRequest?
I have a function that looks for a query parameter and returns a boolean:
public static Boolean getBooleanFromRequest(HttpServletRequest request, String key) {
Boolean keyValue = false;
if(request.getParameter(key) != null) {
String value = request.getParameter(key);
if(keyValue == null) {
keyValue = false;
}
…