use of org.killbill.clock.DistributedClockMock in project killbill by killbill.
the class GuicyKillbillTestSuite method globalBeforeSuite.
@BeforeSuite(alwaysRun = true)
public void globalBeforeSuite() {
extraPropertiesForTestSuite.put("org.killbill.security.shiroResourcePath", "classpath:org/killbill/billing/util/shiro.ini");
if (Boolean.valueOf(System.getProperty("killbill.test.redis", "false"))) {
redisServer = new RedisServer(56379);
redisServer.start();
redissonClient = new RedissonCacheClientProvider("redis://127.0.0.1:56379", 1, null).get();
theRealClock = new DistributedClockMock();
((DistributedClockMock) theRealClock).setRedissonClient(redissonClient);
extraPropertiesForTestSuite.put("org.killbill.cache.config.redis", "true");
extraPropertiesForTestSuite.put("org.killbill.cache.config.redis.url", "redis://127.0.0.1:56379");
} else {
theRealClock.resetDeltaFromReality();
}
// The clock needs to be setup early in @BeforeSuite, as it is needed when starting the server, but see below
clock = theRealClock;
}
Aggregations