@Test
    public void testUnzipWithLimits() {
        // Test contributed by John McClean on
        // https://github.com/jOOQ/jOOL/issues/103
        Supplier<Seq<Tuple2<Integer, String>>> s = () -> Seq.of(
            tuple(1, "a"),
            tuple(2, "b"),
            tuple(3, "c")
        );

        Tuple2<Seq<Integer>, Seq<String>> unzipped;

        // Consume v1 first
        unzipped = Seq.unzip(s.get()).map1(s1 -> s1.limit(2));
        assertEquals(Arrays.asList(1, 2), unzipped.v1.toList());
        assertEquals(Arrays.asList("a", "b", "c"), unzipped.v2.toList());

        // Consume v2 first
        unzipped = Seq.unzip(s.get()).map1(s1 -> s1.limit(2));
        assertEquals(Arrays.asList("a", "b", "c"), unzipped.v2.toList());
        assertEquals(Arrays.asList(1, 2), unzipped.v1.toList());
    }
@author Lukas Eder
@author Roman Tkalenko
jOOL-java-8/src/test/java/org/jooq/lambda/SeqTest.java