public InputStream requestContentOf(Object jacksonEntity) {
        ByteArrayOutputStream out = new ByteArrayOutputStream();
        uncheck(() -> handler.restApi().jacksonJsonMapper().writeValue(out, jacksonEntity));
        return new ByteArrayInputStream(out.toByteArray());
    }
Test driver for {@link RestApi}

@author bjorncs
container-core/src/main/java/com/yahoo/restapi/RestApiTestDriver.java