@Test
public void testZipValuesWithKeyFunc() {

    final Map<Integer, String> lengths = Stream.of("bar", "acme", "baboon")
            .collect(Collectors.toMap(String::length, Function.identity()));
    final Map<String, Integer> collected = Stream.of(4)
            .map(zipValuesWithKeyFunc(lengths::get))
            .collect(Fun.entriesToMap());
    assertEquals("zipValues map should match", Collections.singletonMap("acme", 4), collected);
}