예제 #1
0
        public async Task Can_GetRandomEntryFromSet()
        {
            var storeMembers = Factory.CreateList();
            await storeMembers.ForEachAsync(async x => await redis.AddItemToSetAsync(Set, x));

            var randomEntry = await redis.GetRandomItemFromSetAsync(Set);

            Assert.That(storeMembers.Contains(randomEntry), Is.True);
        }