DistributedEventTracker implements EventTracker { @Override public String getName() { return name; } DistributedEventTracker(InternalCache cache, CancelCriterion stopper, String regionName); @Override void start(); @Override void stop(); @Override void clear(); @Override Map<ThreadIdentifier, EventSequenceNumberHolder> getState(); @Override void recordState(InternalDistributedMember provider,
      Map<ThreadIdentifier, EventSequenceNumberHolder> state); @Override void setInitialized(); @Override void waitOnInitialization(); @Override void recordEvent(InternalCacheEvent event); @Override boolean hasSeenEvent(InternalCacheEvent event); @Override boolean hasSeenEvent(EventID eventID); @Override boolean hasSeenEvent(EventID eventID, InternalCacheEvent tagHolder); @Override VersionTag findVersionTagForSequence(EventID eventID); @Override VersionTag findVersionTagForBulkOp(EventID eventID); @Override String getName(); @Override void syncBulkOp(Runnable r, EventID eventID, boolean partOfTransaction); @Override void recordBulkOpStart(EventID eventID, ThreadIdentifier tid); @Override boolean isInitialized(); @Override boolean isInitialImageProvider(DistributedMember mbr); @Override ConcurrentMap<ThreadIdentifier, BulkOperationHolder> getRecordedBulkOpVersionTags(); @Override ConcurrentMap<ThreadIdentifier, EventSequenceNumberHolder> getRecordedEvents(); @Override String toString();  }
@Test public void returnsCorrectNameOfCache() { String testName = "testing"; when(region.getName()).thenReturn(testName); eventTracker = new DistributedEventTracker(region.getCache(), mock(CancelCriterion.class), region.getName()); assertEquals("Event Tracker for " + testName, eventTracker.getName()); }