Skip to content

Commit 37183b4

Browse files
committed
Add more tests for unclosed paranthesis
1 parent 542c3d3 commit 37183b4

File tree

1 file changed

+10
-1
lines changed

1 file changed

+10
-1
lines changed

x-pack/plugin/esql/src/test/java/org/elasticsearch/xpack/esql/parser/StatementParserTests.java

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4286,7 +4286,16 @@ public void testInvalidDoubleParamsType() {
42864286
}
42874287

42884288
public void testUnclosedParenthesis() {
4289-
String[] queries = { "row a = )", "row ]", "from source | eval x = [1,2,3]]" };
4289+
String[] queries = {
4290+
"row a = )",
4291+
"row ]",
4292+
"from source | eval x = [1,2,3]]",
4293+
"ROW x = 1 | KEEP x )",
4294+
"ROW x = 1 | DROP x )",
4295+
"ROW a = [1, 2] | RENAME a =b)",
4296+
"ROW a = [1, 2] | MV_EXPAND a)",
4297+
"from test | enrich a on b)"
4298+
};
42904299
for (String q : queries) {
42914300
expectError(q, "Invalid query");
42924301
}

0 commit comments

Comments
 (0)