@Test
public void shouldPutRepresentationSupportingIdWithNoResponseBodyAndNoLocation() throws Exception {
// Given
clientParameters.setRequireResponseBody(false);
ManagedObjectRepresentation representation = new ManagedObjectRepresentation();
returnResponseWhenPut(representation);
when(parser.parse(response, 200, ManagedObjectRepresentation.class)).thenReturn(null);
when(response.getLocation()).thenReturn(null);
// When
ManagedObjectRepresentation result = restConnector.put(PATH, mediaType, representation);
// Then
verify(typeBuilder, never()).accept(any(MediaType.class));
assertThat(result, sameInstance(representation));
assertThat(result.getId(), nullValue());
}