@Test
public void testThrowWhileReadingTheInputWeAreHandling() throws B2Exception {

    final InputStream throwingIn = new InputStream() {
        @Override
        public int read() throws IOException {
            throw new IOException("throwing while reading input to handler");
        }
    };
    thrown.expect(B2Exception.class);
    thrown.expectMessage("read failed: throwing while reading input to handler");
    writer.readContent(makeHeaders(LEN), throwingIn);
}