String header =
(String) event.getArgument(String.class);
if (header == null) {
return null;
} else {
return new IteratorEnumeration(Collections
.singletonList(header).iterator());
}
}
}).any();
// requestMock.expects.getHeaders("accept").returns(null).any();
requestMock.expects.getHeaderNames()
.returns(new IteratorEnumeration(headers.keySet().iterator()))
.any();
StringWriter writer = new StringWriter();
// todo Find out why WML sets this twice and fix it.