use of org.apache.rocketmq.connect.redis.parser.XTrimParser in project rocketmq-externals by apache.
the class ParserTest method testXTrimParser2.
@Test
public void testXTrimParser2() {
String command = "XTrim key MAXLEN 100";
KVEntry builder = new XTrimParser().parse(parseCommand(command));
Assert.assertEquals("XTrim", builder.getCommand());
Assert.assertEquals("key", builder.getKey());
Assert.assertEquals(false, builder.getParam(Options.REDIS_XTRIM));
}
use of org.apache.rocketmq.connect.redis.parser.XTrimParser in project rocketmq-externals by apache.
the class ParserTest method testXTrimParser.
@Test
public void testXTrimParser() {
String command = "XTrim key MAXLEN ~ 100";
KVEntry builder = new XTrimParser().parse(parseCommand(command));
Assert.assertEquals("XTrim", builder.getCommand());
Assert.assertEquals("key", builder.getKey());
Assert.assertEquals(true, builder.getParam(Options.REDIS_XTRIM));
}
Aggregations