@Test
public void mapA() {

    Pair<Double, String> expectedResult = Pair.of(2.5, "a");
    Optional<Pair<Integer, String>> boxedPair = Optional.of(Pair.of(1, "a"));
    Pair<Double, String> result = boxedPair.map(Pair.mapA(a -> a + 1.5)).get();
    assertEquals(expectedResult, result);
}