### Question:
CompatibleHistorySegment extends CacheColumnSegment implements HistorySegment { @Override public ImmutableBitMap getAllShowIndex() { if (allShowBitMapCache != null) { return allShowBitMapCache; } allShowBitMapCache = super.getAllShowIndex(); return allShowBitMapCache; } CompatibleHistorySegment(IResourceLocation parent, SwiftMetaData meta); @Override ImmutableBitMap getAllShowIndex(); @Override void release();  }### Answer:
@Test public void getAllShowIndex() { ImmutableBitMap bitmap = mock(ImmutableBitMap.class); when(bitmapReader.get(0)).thenReturn(bitmap, mock(ImmutableBitMap.class)); CompatibleHistorySegment seg = new CompatibleHistorySegment(new ResourceLocation("/"), mock(SwiftMetaData.class)); assertEquals(bitmap, seg.getAllShowIndex()); assertEquals(bitmap, seg.getAllShowIndex()); }