@Test
public void mapFromAttributes() throws NamingException {

    // given
    var expectedId = "user-id";
    var expectedThumbnailPhoto = new byte[] {-2, 10, 39, 32};
    var expectedEntry = Map.entry(expectedId, expectedThumbnailPhoto);
    var idAttr = new BasicAttribute(ID_ATTR_VALUE, expectedId);
    var thumbnailPhotoAttr = new BasicAttribute("thumbnailPhoto", expectedThumbnailPhoto);
    var attributes = new BasicAttributes();
    attributes.put(idAttr);
    attributes.put(thumbnailPhotoAttr);
    // when
    var actualEntry = mapper.mapFromAttributes(attributes);
    // then
    assertThat(actualEntry).isEqualTo(expectedEntry);
}