use of org.apache.rocketmq.connect.redis.parser.ZRemRangeByRankParser in project rocketmq-externals by apache.
the class ParserTest method testZRemRangeByRankParser.
@Test
public void testZRemRangeByRankParser() {
String command = "ZREMRANGEBYRANK key 0 10";
KVEntry builder = new ZRemRangeByRankParser().parse(parseCommand(command));
Assert.assertEquals("ZREMRANGEBYRANK", builder.getCommand());
Assert.assertEquals("key", builder.getKey());
List<String> res = (List<String>) builder.getValue();
Assert.assertEquals(2, res.size());
Assert.assertEquals("0", res.get(0));
Assert.assertEquals("10", res.get(1));
}
Aggregations