summaryrefslogtreecommitdiffstats
path: root/tests/test_expressions.py
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2022-12-02 09:16:29 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2022-12-02 09:16:29 +0000
commit1a60bbae98d3b530924a6807a55f8250de19ea86 (patch)
tree87d3000f271a6604fff43db188731229aed918a8 /tests/test_expressions.py
parentAdding upstream version 10.0.8. (diff)
downloadsqlglot-1a60bbae98d3b530924a6807a55f8250de19ea86.tar.xz
sqlglot-1a60bbae98d3b530924a6807a55f8250de19ea86.zip
Adding upstream version 10.1.3.upstream/10.1.3
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'tests/test_expressions.py')
-rw-r--r--tests/test_expressions.py28
1 files changed, 9 insertions, 19 deletions
diff --git a/tests/test_expressions.py b/tests/test_expressions.py
index c0927ad..0e13ade 100644
--- a/tests/test_expressions.py
+++ b/tests/test_expressions.py
@@ -525,24 +525,14 @@ class TestExpressions(unittest.TestCase):
),
exp.Properties(
expressions=[
- exp.FileFormatProperty(
- this=exp.Literal.string("FORMAT"), value=exp.Literal.string("parquet")
- ),
+ exp.FileFormatProperty(this=exp.Literal.string("parquet")),
exp.PartitionedByProperty(
- this=exp.Literal.string("PARTITIONED_BY"),
- value=exp.Tuple(
- expressions=[exp.to_identifier("a"), exp.to_identifier("b")]
- ),
- ),
- exp.AnonymousProperty(
- this=exp.Literal.string("custom"), value=exp.Literal.number(1)
- ),
- exp.TableFormatProperty(
- this=exp.Literal.string("TABLE_FORMAT"),
- value=exp.to_identifier("test_format"),
+ this=exp.Tuple(expressions=[exp.to_identifier("a"), exp.to_identifier("b")])
),
- exp.EngineProperty(this=exp.Literal.string("ENGINE"), value=exp.null()),
- exp.CollateProperty(this=exp.Literal.string("COLLATE"), value=exp.true()),
+ exp.Property(this=exp.Literal.string("custom"), value=exp.Literal.number(1)),
+ exp.TableFormatProperty(this=exp.to_identifier("test_format")),
+ exp.EngineProperty(this=exp.null()),
+ exp.CollateProperty(this=exp.true()),
]
),
)
@@ -609,9 +599,9 @@ FROM foo""",
"""SELECT
a,
b AS B,
- c, -- comment
- d AS D, -- another comment
- CAST(x AS INT) -- final comment
+ c, /* comment */
+ d AS D, /* another comment */
+ CAST(x AS INT) /* final comment */
FROM foo""",
)