Skip to content

Commit

Permalink
add testEntrySetAfterExpiryWithStore
Browse files Browse the repository at this point in the history
  • Loading branch information
mlinhard committed Sep 13, 2013
1 parent 5b1f2eb commit c8390f2
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions core/src/test/java/org/infinispan/expiry/ExpiryTest.java
@@ -1,6 +1,7 @@
package org.infinispan.expiry;

import org.infinispan.Cache;
import org.infinispan.configuration.cache.ConfigurationBuilder;
import org.infinispan.container.DataContainer;
import org.infinispan.container.entries.InternalCacheEntry;
import org.infinispan.manager.CacheContainer;
Expand Down Expand Up @@ -241,10 +242,25 @@ public void testEntrySetAfterExpiryInTransaction(Method m) throws Exception {
}
}

public void testEntrySetAfterExpiryWithStore(Method m) throws Exception {
CacheContainer cc = createCacheContainerWithStore();
try {
doTestEntrySetAfterExpiryInPut(m, cc);
} finally {
cc.stop();
}
}

private CacheContainer createTransactionalCacheContainer() {
return TestCacheManagerFactory.createCacheManager(TestCacheManagerFactory.getDefaultCacheConfiguration(true));
}

private CacheContainer createCacheContainerWithStore() {
ConfigurationBuilder b = new ConfigurationBuilder();
b.persistence().addSingleFileStore();
return TestCacheManagerFactory.createCacheManager(b);
}

private void doTestEntrySetAfterExpiryInPut(Method m, CacheContainer cc) throws Exception {
Cache<Integer, String> cache = cc.getCache();
Set<Map.Entry<Integer, String>> entries;
Expand Down

0 comments on commit c8390f2

Please sign in to comment.