public override void Before(MethodInfo methodUnderTest) { Monitor.Enter(GlobalLock); var client = RedisUtils.CreateClient(); client.Multiplexer.GetServer(RedisUtils.GetHostAndPort()).FlushDatabase(RedisUtils.GetDb()); }
public RedisConnectionFacts() { var options = new RedisStorageOptions() { Db = RedisUtils.GetDb() }; _storage = new RedisStorage(RedisUtils.GetHostAndPort(), options); }
private RedisStorage CreateStorage() { var options = new RedisStorageOptions() { Db = RedisUtils.GetDb() }; return(new RedisStorage(RedisUtils.GetHostAndPort(), options)); }
public FetchedJobsWatcherFacts() { var options = new RedisStorageOptions() { Db = RedisUtils.GetDb() }; _storage = new RedisStorage(RedisUtils.GetHostAndPort(), options); _cts = new CancellationTokenSource(); _cts.Cancel(); }
public RedisWriteOnlyTransactionFacts() { var options = new RedisStorageOptions() { Db = RedisUtils.GetDb() }; _storage = new RedisStorage(RedisUtils.GetHostAndPort(), options); _transaction = new Mock <ITransaction>(); }
public RedisFetchedJobFacts() { _redis = new Mock <IDatabase>(); var options = new RedisStorageOptions() { Db = RedisUtils.GetDb() }; _storage = new RedisStorage(RedisUtils.GetHostAndPort(), options); }
public RedisSubscriptionFacts() { _cts = new CancellationTokenSource(); var options = new RedisStorageOptions() { Db = RedisUtils.GetDb() }; _storage = new RedisStorage(RedisUtils.GetHostAndPort(), options); _subscriber = new Mock <ISubscriber>(); }
public FetchedJobsWatcherFacts() { _storage = new RedisStorage(RedisUtils.GetHostAndPort(), RedisUtils.GetDb()); _cts = new CancellationTokenSource(); _cts.Cancel(); }
private RedisStorage CreateStorage() { return(new RedisStorage(RedisUtils.GetHostAndPort(), RedisUtils.GetDb())); }
public void DbFromConnectionStringIsUsed() { var storage = new RedisStorage(String.Format("{0},defaultDatabase=5", RedisUtils.GetHostAndPort())); Assert.Equal(storage.Db, 5); }