From a95fd7b7de8c3492d8267b2007508d579ff50848 Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Mon, 23 Dec 2024 20:51:10 +0100 Subject: Merging upstream version 26.0.1. Signed-off-by: Daniel Baumann --- tests/test_optimizer.py | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'tests/test_optimizer.py') diff --git a/tests/test_optimizer.py b/tests/test_optimizer.py index 4a41e4a..7f2ed0d 100644 --- a/tests/test_optimizer.py +++ b/tests/test_optimizer.py @@ -551,6 +551,10 @@ class TestOptimizer(unittest.TestCase): SELECT :with,WITH :expressions,CTE :this,UNION :this,SELECT :expressions,1,:expression,SELECT :expressions,2,:distinct,True,:alias, AS cte,CTE :this,SELECT :expressions,WINDOW :this,ROW(),:partition_by,y,:over,OVER,:from,FROM ((SELECT :expressions,1):limit,LIMIT :expression,10),:alias, AS cte2,:expressions,STAR,a + 1,a DIV 1,FILTER("B",LAMBDA :this,x + y,:expressions,x,y),:from,FROM (z AS z:joins,JOIN :this,z,:kind,CROSS) AS f(a),:joins,JOIN :this,a.b.c.d.e.f.g,:side,LEFT,:using,n,:order,ORDER :expressions,ORDERED :this,1,:nulls_first,True """.strip(), ) + self.assertEqual( + optimizer.simplify.gen(parse_one("select item_id /* description */"), comments=True), + "SELECT :expressions,item_id /* description */", + ) def test_unnest_subqueries(self): self.check_file("unnest_subqueries", optimizer.unnest_subqueries.unnest_subqueries) -- cgit v1.2.3