use of io.confluent.ksql.parser.ExpressionParser.parseSelectExpression in project ksql by confluentinc.
the class ExpressionParserTest method shouldParseSelectExpression.
@Test
public void shouldParseSelectExpression() {
// When:
final SelectExpression parsed = ExpressionParser.parseSelectExpression("1 + 2 AS `three`");
// Then:
assertThat(parsed, equalTo(SelectExpression.of(ColumnName.of("three"), new ArithmeticBinaryExpression(parsed.getExpression().getLocation(), Operator.ADD, ONE, TWO))));
}
Aggregations