bucket.getName(), format);
}
@SuppressWarnings("unchecked")
public void resolveBucketsFormats_givenBucketToResolveForAndChosenFormat_bucketWithFormatIndexAndName() {
Bucket bucket = TUtilsBucket.createBucket();
BucketFormat format = BucketFormat.SPLUNK_BUCKET;
when(bucketFormatChooser.chooseBucketFormat(anyList())).thenReturn(format);
List<Bucket> bucketsWithFormat = bucketFormatResolver
.resolveBucketsFormats(Arrays.asList(bucket));
// Verify
assertEquals(1, bucketsWithFormat.size());
assertEquals(format, bucketsWithFormat.get(0).getFormat());
assertEquals(bucket.getIndex(), bucketsWithFormat.get(0).getIndex());
assertEquals(bucket.getName(), bucketsWithFormat.get(0).getName());
}