292293294295296297298299300301302
bucketer.reset(dir); for (int i = 0; i < input.size(); i++) { FileStatus file = input.get(i); bucketer.add(new FileStatusHasSize(file)); assertThat(dir, bucketer.count(), equalTo(i + 1)); } List<Bucket> actual = bucketer.createBuckets();
38394041424344
bucketer = new Bucketer(5, 50, true); } @Test(expected = IllegalStateException.class) public void callAddBeforeReset() { bucketer.add(new FileStatusHasSize(new FileStatus())); }