use of org.hibernate.event.spi.SaveOrUpdateEvent in project BridgeServer2 by Sage-Bionetworks.
the class TagEventListenerTest method onSaveOrUpdateNotTag.
@Test
public void onSaveOrUpdateNotTag() throws HibernateException {
SaveOrUpdateEvent event = new SaveOrUpdateEvent(new HibernateAssessment(), null);
listener.onSaveOrUpdate(event);
verify(cacheProvider, never()).removeObject(CacheKey.tagList());
}
use of org.hibernate.event.spi.SaveOrUpdateEvent in project BridgeServer2 by Sage-Bionetworks.
the class TagEventListenerTest method onSaveOrUpdate.
@Test
public void onSaveOrUpdate() throws HibernateException {
SaveOrUpdateEvent event = new SaveOrUpdateEvent(new Tag("value"), null);
listener.onSaveOrUpdate(event);
verify(cacheProvider).removeObject(CacheKey.tagList());
}
Aggregations