public async void Del() { var add = await DB.Set("test", "henryfan"); Write(add); var del = await DB.Del("test"); Write(del); }
public async void SCARD() { await DB.Flushall(); var sets = GetSets(); var count = await sets.SAdd("tool", "pc", "printer", "phone"); var len = await sets.SCard("tool"); Assert.Equal(3, len); await DB.Del("tool"); len = await sets.SCard("tool"); Assert.Equal(0, len); }
public async void ZAdd() { await DB.Del("seq2"); var sequeue = DB.CreateSequence("seq2"); var count = await sequeue.ZAdd((1, Guid.NewGuid().ToString("N")), (2, Guid.NewGuid().ToString("N"))); Assert.Equal <long>(count, 2); Write(count); }