From 5404cdd4d0f3e038738b05104c28f40cb792cd9a Mon Sep 17 00:00:00 2001 From: xiaowei Date: Wed, 8 Sep 2021 20:23:58 +0800 Subject: [PATCH] test: unit test for the custom variables --- test/parser/spark/syntax.test.ts | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/test/parser/spark/syntax.test.ts b/test/parser/spark/syntax.test.ts index a6c1375..d194e59 100644 --- a/test/parser/spark/syntax.test.ts +++ b/test/parser/spark/syntax.test.ts @@ -312,4 +312,13 @@ SELECT * FROM t2;`, ]; validateTest(sqls); }); + + test('Customizing variables with the ${} symbol', () => { + const sqls = [ + `select * from \${tb};`, + `select a as \${b_} from tb_test;`, + 'select a as ${bb} from ${tt}', + ]; + validateTest(sqls); + }); });