@Test
public void testLazyFlatMapHasNext() {

  Iterator<Integer> ints = mlazy(asList(1, 2)).flatMap(MonadicsTest.<Integer>twice()).value();
  // test correctness of hasNext()
  assertTrue(ints.hasNext());
  assertTrue(ints.hasNext());
  assertTrue(ints.hasNext());
  assertTrue(ints.hasNext());
  assertTrue(ints.hasNext());
}