Skip to content

Commit 189d0ff

Browse files
committed
Fix regression tests for better stability
Per buildfarm
1 parent 8b08f7d commit 189d0ff

File tree

2 files changed

+18
-18
lines changed

2 files changed

+18
-18
lines changed

src/test/regress/expected/indexing.out

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -224,26 +224,26 @@ Partition of: idxpart2 FOR VALUES FROM (100) TO (200)
224224
select indexrelid::regclass, indrelid::regclass, inhparent::regclass
225225
from pg_index idx left join pg_inherits inh on (idx.indexrelid = inh.inhrelid)
226226
where indexrelid::regclass::text like 'idxpart%'
227-
order by indrelid::regclass::text collate "C";
227+
order by indexrelid::regclass::text collate "C";
228228
indexrelid | indrelid | inhparent
229229
-----------------+-----------+---------------
230-
idxpart_a_idx | idxpart |
231230
idxpart1_a_idx | idxpart1 | idxpart_a_idx
232-
idxpart2_a_idx | idxpart2 | idxpart_a_idx
233231
idxpart22_a_idx | idxpart22 |
232+
idxpart2_a_idx | idxpart2 | idxpart_a_idx
233+
idxpart_a_idx | idxpart |
234234
(4 rows)
235235

236236
alter index idxpart2_a_idx attach partition idxpart22_a_idx;
237237
select indexrelid::regclass, indrelid::regclass, inhparent::regclass
238238
from pg_index idx left join pg_inherits inh on (idx.indexrelid = inh.inhrelid)
239239
where indexrelid::regclass::text like 'idxpart%'
240-
order by indrelid::regclass::text collate "C";
240+
order by indexrelid::regclass::text collate "C";
241241
indexrelid | indrelid | inhparent
242242
-----------------+-----------+----------------
243-
idxpart_a_idx | idxpart |
244243
idxpart1_a_idx | idxpart1 | idxpart_a_idx
245-
idxpart2_a_idx | idxpart2 | idxpart_a_idx
246244
idxpart22_a_idx | idxpart22 | idxpart2_a_idx
245+
idxpart2_a_idx | idxpart2 | idxpart_a_idx
246+
idxpart_a_idx | idxpart |
247247
(4 rows)
248248

249249
-- attaching idxpart22 is not enough to set idxpart22_a_idx valid ...
@@ -600,15 +600,15 @@ alter table idxpart attach partition idxpart2 for values from (10) to (20);
600600
select c.relname, pg_get_indexdef(indexrelid)
601601
from pg_class c join pg_index i on c.oid = i.indexrelid
602602
where indrelid::regclass::text like 'idxpart%'
603-
order by indrelid::regclass::text collate "C";
603+
order by indexrelid::regclass::text collate "C";
604604
relname | pg_get_indexdef
605605
------------------+--------------------------------------------------------------
606-
idxparti | CREATE INDEX idxparti ON ONLY idxpart USING btree (a)
607-
idxparti2 | CREATE INDEX idxparti2 ON ONLY idxpart USING btree (c, b)
608606
idxpart1_a_idx | CREATE INDEX idxpart1_a_idx ON idxpart1 USING btree (a)
609607
idxpart1_c_b_idx | CREATE INDEX idxpart1_c_b_idx ON idxpart1 USING btree (c, b)
610608
idxpart2_a_idx | CREATE INDEX idxpart2_a_idx ON idxpart2 USING btree (a)
611609
idxpart2_c_b_idx | CREATE INDEX idxpart2_c_b_idx ON idxpart2 USING btree (c, b)
610+
idxparti | CREATE INDEX idxparti ON ONLY idxpart USING btree (a)
611+
idxparti2 | CREATE INDEX idxparti2 ON ONLY idxpart USING btree (c, b)
612612
(6 rows)
613613

614614
drop table idxpart;
@@ -626,12 +626,12 @@ alter table idxpart attach partition idxpart1 for values from (1) to (2);
626626
select c.relname, pg_get_indexdef(indexrelid)
627627
from pg_class c join pg_index i on c.oid = i.indexrelid
628628
where indrelid::regclass::text like 'idxpart%'
629-
order by indrelid::regclass::text collate "C";
629+
order by indexrelid::regclass::text collate "C";
630630
relname | pg_get_indexdef
631631
------------------+-------------------------------------------------------------------
632-
idxpart_abs_idx | CREATE INDEX idxpart_abs_idx ON ONLY idxpart USING btree (abs(b))
633632
idxpart1_abs_idx | CREATE INDEX idxpart1_abs_idx ON idxpart1 USING btree (abs(b))
634633
idxpart2_abs_idx | CREATE INDEX idxpart2_abs_idx ON idxpart2 USING btree (abs(b))
634+
idxpart_abs_idx | CREATE INDEX idxpart_abs_idx ON ONLY idxpart USING btree (abs(b))
635635
(3 rows)
636636

637637
drop table idxpart;
@@ -649,12 +649,12 @@ create index on idxpart (a) where b > 1000;
649649
select c.relname, pg_get_indexdef(indexrelid)
650650
from pg_class c join pg_index i on c.oid = i.indexrelid
651651
where indrelid::regclass::text like 'idxpart%'
652-
order by indrelid::regclass::text collate "C";
652+
order by indexrelid::regclass::text collate "C";
653653
relname | pg_get_indexdef
654654
----------------+-----------------------------------------------------------------------------
655-
idxpart_a_idx | CREATE INDEX idxpart_a_idx ON ONLY idxpart USING btree (a) WHERE (b > 1000)
656655
idxpart1_a_idx | CREATE INDEX idxpart1_a_idx ON idxpart1 USING btree (a) WHERE (b > 1000)
657656
idxpart2_a_idx | CREATE INDEX idxpart2_a_idx ON idxpart2 USING btree (a) WHERE (b > 1000)
657+
idxpart_a_idx | CREATE INDEX idxpart_a_idx ON ONLY idxpart USING btree (a) WHERE (b > 1000)
658658
(3 rows)
659659

660660
drop table idxpart;

src/test/regress/sql/indexing.sql

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -116,12 +116,12 @@ create index on idxpart (a);
116116
select indexrelid::regclass, indrelid::regclass, inhparent::regclass
117117
from pg_index idx left join pg_inherits inh on (idx.indexrelid = inh.inhrelid)
118118
where indexrelid::regclass::text like 'idxpart%'
119-
order by indrelid::regclass::text collate "C";
119+
order by indexrelid::regclass::text collate "C";
120120
alter index idxpart2_a_idx attach partition idxpart22_a_idx;
121121
select indexrelid::regclass, indrelid::regclass, inhparent::regclass
122122
from pg_index idx left join pg_inherits inh on (idx.indexrelid = inh.inhrelid)
123123
where indexrelid::regclass::text like 'idxpart%'
124-
order by indrelid::regclass::text collate "C";
124+
order by indexrelid::regclass::text collate "C";
125125
-- attaching idxpart22 is not enough to set idxpart22_a_idx valid ...
126126
alter index idxpart2_a_idx attach partition idxpart22_a_idx;
127127
\d idxpart2
@@ -306,7 +306,7 @@ alter table idxpart attach partition idxpart2 for values from (10) to (20);
306306
select c.relname, pg_get_indexdef(indexrelid)
307307
from pg_class c join pg_index i on c.oid = i.indexrelid
308308
where indrelid::regclass::text like 'idxpart%'
309-
order by indrelid::regclass::text collate "C";
309+
order by indexrelid::regclass::text collate "C";
310310
drop table idxpart;
311311

312312
-- Verify that columns are mapped correctly in expression indexes
@@ -323,7 +323,7 @@ alter table idxpart attach partition idxpart1 for values from (1) to (2);
323323
select c.relname, pg_get_indexdef(indexrelid)
324324
from pg_class c join pg_index i on c.oid = i.indexrelid
325325
where indrelid::regclass::text like 'idxpart%'
326-
order by indrelid::regclass::text collate "C";
326+
order by indexrelid::regclass::text collate "C";
327327
drop table idxpart;
328328

329329
-- Verify that columns are mapped correctly for WHERE in a partial index
@@ -340,7 +340,7 @@ create index on idxpart (a) where b > 1000;
340340
select c.relname, pg_get_indexdef(indexrelid)
341341
from pg_class c join pg_index i on c.oid = i.indexrelid
342342
where indrelid::regclass::text like 'idxpart%'
343-
order by indrelid::regclass::text collate "C";
343+
order by indexrelid::regclass::text collate "C";
344344
drop table idxpart;
345345

346346
-- Column number mapping: dropped columns in the partition

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy