public void ZcardTest() { var key = $"{nameof(ZcardTest)}Key"; string result; result = _client.Zadd(key, new[] { "1", "a", "2", "b", "3", "c" }); Assert.AreEqual("3", result); result = _client.Zcard(key); Assert.AreEqual("3", result); }
public object Execute(string[] args) { if (args.Length < 2) { throw new ArgumentException("(error) wrong number of arguments"); } var key = args[1]; var result = _client.Zcard(key); return(result); }