@Test
public void acknowledgementToAdaptable() {

    final DittoHeaders dittoHeaders = DittoHeaders.newBuilder().randomCorrelationId().build();
    final JsonValue customAckPayload = JsonObject.newBuilder().set("foo", "bar").build();
    final HttpStatusCode status = HttpStatusCode.BAD_REQUEST;
    final Acknowledgement acknowledgement = ThingAcknowledgementFactory.newAcknowledgement(KNOWN_CUSTOM_LABEL,
            TestConstants.THING_ID,
            status,
            dittoHeaders,
            customAckPayload);
    final Adaptable expected = Adaptable.newBuilder(topicPathMyCustomAck)
            .withPayload(Payload.newBuilder(JsonPointer.empty())
                    .withValue(customAckPayload)
                    .withStatus(status)
                    .build())
            .withHeaders(dittoHeaders)
            .build();
    final Adaptable actual = underTest.toAdaptable(acknowledgement);
    assertWithExternalHeadersThat(actual).isEqualTo(expected);
}