@SuppressWarnings("unchecked")
@Test
public void readsContentOfEntityStreamAsMultivaluedMapWhenFormFieldMissedValue() throws Exception {

    testContent = "foo&bar=hello%20world".getBytes("UTF-8");
    MultivaluedMap<String, String> multivaluedMap = multivaluedMapEntityProvider.readFrom((Class)MultivaluedMap.class,
                                                                                          multiValuedMapGenericType,
                                                                                          null, APPLICATION_FORM_URLENCODED_TYPE,
                                                                                          new MultivaluedMapImpl(),
                                                                                          new ByteArrayInputStream(testContent));
    Map<String, List<String>> decodedMap = ImmutableMap.of("foo", newArrayList(""), "bar", newArrayList("hello world"));
    assertEquals(decodedMap, multivaluedMap);
}