diff options
author | Duarte Meneses <duarte.meneses@sonarsource.com> | 2015-09-30 15:16:56 +0200 |
---|---|---|
committer | Duarte Meneses <duarte.meneses@sonarsource.com> | 2015-10-01 14:34:34 +0200 |
commit | 943e74fd412f701247e1bea5aa3760418a10ec0d (patch) | |
tree | 7ae154b773b7cc92903825f6359b9400bac8c4be /sonar-batch/src | |
parent | 3badd476071ad30333b9a1a4080531e84953b6e4 (diff) | |
download | sonarqube-943e74fd412f701247e1bea5aa3760418a10ec0d.tar.gz sonarqube-943e74fd412f701247e1bea5aa3760418a10ec0d.zip |
Decouple cache invalidation criteria
Diffstat (limited to 'sonar-batch/src')
-rw-r--r-- | sonar-batch/src/test/java/org/sonar/batch/cache/WSLoaderTestWithServer.java | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/sonar-batch/src/test/java/org/sonar/batch/cache/WSLoaderTestWithServer.java b/sonar-batch/src/test/java/org/sonar/batch/cache/WSLoaderTestWithServer.java index 1781a143f89..def5566c274 100644 --- a/sonar-batch/src/test/java/org/sonar/batch/cache/WSLoaderTestWithServer.java +++ b/sonar-batch/src/test/java/org/sonar/batch/cache/WSLoaderTestWithServer.java @@ -21,11 +21,12 @@ package org.sonar.batch.cache; import static org.mockito.Mockito.mock; +import org.sonar.home.cache.TTLCacheInvalidation; + import org.sonar.batch.bootstrap.GlobalProperties; import org.sonar.batch.bootstrap.MockHttpServer; import org.sonar.batch.bootstrap.ServerClient; import org.sonar.batch.bootstrap.Slf4jLogger; - import org.sonar.batch.cache.WSLoader; import org.sonar.batch.cache.WSLoader.LoadStrategy; import org.junit.Rule; @@ -57,7 +58,7 @@ public class WSLoaderTestWithServer { when(bootstrapProps.property("sonar.host.url")).thenReturn("http://localhost:" + server.getPort()); client = new ServerClient(bootstrapProps, new EnvironmentInformation("Junit", "4")); - cache = new PersistentCache(temp.getRoot().toPath(), 1000 * 60, new Slf4jLogger(), null); + cache = new PersistentCache(temp.getRoot().toPath(), new TTLCacheInvalidation(100_000L), new Slf4jLogger(), null); } @After |