<commit_before>package ciir.jfoley.chai.collections.iters;

import org.junit.Test;

import java.util.Arrays;
import java.util.List;

import static org.junit.Assert.assertEquals;

/**
 * @author jfoley
 */
public class GroupByIteratorTest {

  @Test
  public void testLazyGroupBy() {
    List<Integer> data = Arrays.asList(3,3,3,2,2,1,4,4,4,4,6,6,6,6,6,6);

    for (List<Integer> xs : new OneShotIterable<>(new GroupByIterator<>(data.iterator()))) {
      int value = xs.get(0);
      assertEquals(value, xs.size());
    }
  }

}<commit_msg>Clarify input data for test<commit_after>package ciir.jfoley.chai.collections.iters;

import org.junit.Test;

import java.util.Arrays;
import java.util.List;

import static org.junit.Assert.assertEquals;

/**
 * @author jfoley
 */
public class GroupByIteratorTest {

  @Test
  public void testLazyGroupBy() {
    List<Integer> data = Arrays.asList(
        3,3,3,
        2,2,
        1,
        4,4,4,4,
        6,6,6,6,6,6);

    for (List<Integer> xs : new OneShotIterable<>(new GroupByIterator<>(data.iterator()))) {
      int value = xs.get(0);
      assertEquals(value, xs.size());
    }
  }

}
{'fraction_non_alphanumeric': 0.15249780893952672, 'fraction_numerical': 0.029798422436459245, 'mean_word_length': 3.4609375, 'pattern_counts': {'":': 0, '<': 11, '<?xml version=': 0, '>': 11, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2278760', 'n_tokens_mistral': 431, 'n_tokens_neox': 425, 'n_words': 77}