@Test
public void forExternalMessageWithBytePayload() {

    final byte[] bytePayload = "{ \"foo\":\"bar\" }".getBytes();
    final String expectedBase64Payload = Base64.getEncoder().encodeToString(bytePayload);
    final ExternalMessage externalMessage = ExternalMessageFactory.newExternalMessageBuilder(new HashMap<>())
            .withBytes(bytePayload)
            .build();
    final ConnectionMonitor.InfoProvider info = InfoProviderFactory.forExternalMessage(externalMessage);
    assertThat(info).hasPayload(expectedBase64Payload);
}