expect(mockDataContainer.size()).andAnswer(sg).anyTimes();
Iterator mockIterator = createMock(Iterator.class);
expect(mockIterator.hasNext()).andReturn(true).anyTimes();
expect(mockIterator.next()).andReturn(InternalEntryFactory.create("key", "value")).anyTimes();
expect(mockDataContainer.iterator()).andReturn(mockIterator).once();
mockCache.evict(eq("key"));
expectLastCall().times(3);
replay(mockDataContainer, mockIterator, mockCache);
em.processEviction();
verify(mockDataContainer, mockIterator, mockCache);