Skip to content

Commit 55c925d

Browse files
committed
better test
1 parent 440c789 commit 55c925d

2 files changed

Lines changed: 12 additions & 0 deletions

File tree

packages/kbn-esql-validation-autocomplete/src/validation/esql_validation_meta_tests.json

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -213,6 +213,14 @@
213213
"error": [],
214214
"warning": []
215215
},
216+
{
217+
"query": "from `index`",
218+
"error": [
219+
"SyntaxError: token recognition error at: '`'",
220+
"SyntaxError: token recognition error at: '`'"
221+
],
222+
"warning": []
223+
},
216224
{
217225
"query": "from index, other_index",
218226
"error": [],

packages/kbn-esql-validation-autocomplete/src/validation/validation.test.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -411,6 +411,10 @@ describe('validation logic', () => {
411411
testErrorsAndWarnings(`from index`, []);
412412
testErrorsAndWarnings(`FROM index`, []);
413413
testErrorsAndWarnings(`FrOm index`, []);
414+
testErrorsAndWarnings('from `index`', [
415+
"SyntaxError: token recognition error at: '`'",
416+
"SyntaxError: token recognition error at: '`'",
417+
]);
414418

415419
testErrorsAndWarnings(`from index, other_index`, []);
416420
testErrorsAndWarnings(`from index, missingIndex`, ['Unknown index [missingIndex]']);

0 commit comments

Comments
 (0)