@SuppressWarnings("unchecked")
@Test
public void testPersistWithPersistenceEnabled() {

    doReturn(true).when(mockDelegateProvider).isRecoveryApplicable();
    provider.persist(mockPersistentLogEntry, mockProcedure);
    verify(mockDelegateProvider).persist(mockPersistentLogEntry, mockProcedure);
    provider.persist(mockNonPersistentLogEntry, mockProcedure);
    verify(mockDelegateProvider).persist(mockNonPersistentLogEntry, mockProcedure);
    provider.persist(OTHER_DATA_OBJECT, mockProcedure);
    verify(mockDelegateProvider).persist(OTHER_DATA_OBJECT, mockProcedure);
}