use of org.xwiki.notifications.filters.expression.LesserThanNode in project xwiki-platform by xwiki.
the class ExpressionNodeToHQLConverterTest method parseWithLesserThanNode.
@Test
public void parseWithLesserThanNode() {
AbstractNode testAST = new LesserThanNode(new PropertyValueNode(EventProperty.DATE), new StringValueNode(TEST_VALUE_1));
ExpressionNodeToHQLConverter.HQLQuery result = parser.parse(testAST);
assertEquals(String.format("event.date <= :%s", TEST_VALUE_1_IDENTIFIER), result.getQuery());
assertEquals(TEST_VALUE_1, result.getQueryParameters().get(TEST_VALUE_1_IDENTIFIER));
}
Aggregations