ContentLengthStrategy lenStrategy = new StrictContentLengthStrategy();
HttpMessage message = new HttpMessageMockup();
message.addHeader("Transfer-Encoding", "whatever");
try {
lenStrategy.determineLength(message);
fail("ProtocolException should have been thrown");
} catch (ProtocolException ex) {
// expected
}
}