### Question:
NotifyingPersistenceDecorator implements EventStorePersistence { @Override public boolean existsStream(String bucketId, String streamId) { return persistence.existsStream(bucketId, streamId); } NotifyingPersistenceDecorator(
            EventStorePersistence persistence,
            EventStoreCommitNotifier notifier); @Override boolean existsStream(String bucketId, String streamId); @Override Iterator<ChangeSet> allChanges(String bucketId); @Override Iterator<ChangeSet> getFrom(String bucketId, String streamId, long minVersion, long maxVersion); @Override void persistChanges(ChangeSet changeSet);  }### Answer:
@Test public void test_existsStream() { NotifyingPersistenceDecorator decorator = new NotifyingPersistenceDecorator(this, null); assertEquals(existsStreamCalled, false); assertEquals(decorator.existsStream("FOO", "BAR"), true); assertEquals(existsStreamCalled, true); assertEquals(decorator.existsStream("FOO", "BAR"), false); assertEquals(existsStreamCalled, false); }