Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit86fa9b2

Browse files
committed
Make sepgsql regression tests robust vs. collation differences
In commit25542d7, regression test coverage was added to sepgsqlfor partitioned tables. Unfortunately it was not robust in the faceof collation differences, per the buildfarm. Force "C" collationin order to fix that.Discussion:https://postgr.es/m/flat/623bcaae-112e-ced0-8c22-a84f75ae0c53%40joeconway.com
1 parent25542d7 commit86fa9b2

File tree

4 files changed

+12
-12
lines changed

4 files changed

+12
-12
lines changed

‎contrib/sepgsql/expected/dml.out

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -55,18 +55,18 @@ SELECT objtype, objname, label FROM pg_seclabels
5555
't1p', 't1p.o', 't1p.p', 't1p.q',
5656
't1p_ones', 't1p_ones.o', 't1p_ones.p', 't1p_ones.q',
5757
't1p_tens', 't1p_tens.o', 't1p_tens.p', 't1p_tens.q')
58-
ORDER BY objname;
58+
ORDER BY objname COLLATE "C";
5959
objtype | objname | label
6060
---------+------------+---------------------------------------------
6161
table | t1 | system_u:object_r:sepgsql_table_t:s0
6262
table | t1p | system_u:object_r:sepgsql_table_t:s0
6363
column | t1p.o | system_u:object_r:sepgsql_table_t:s0
64+
column | t1p.p | system_u:object_r:sepgsql_ro_table_t:s0
65+
column | t1p.q | system_u:object_r:sepgsql_secret_table_t:s0
6466
table | t1p_ones | unconfined_u:object_r:sepgsql_table_t:s0
6567
column | t1p_ones.o | system_u:object_r:sepgsql_table_t:s0
6668
column | t1p_ones.p | system_u:object_r:sepgsql_ro_table_t:s0
6769
column | t1p_ones.q | system_u:object_r:sepgsql_secret_table_t:s0
68-
column | t1p.p | system_u:object_r:sepgsql_ro_table_t:s0
69-
column | t1p.q | system_u:object_r:sepgsql_secret_table_t:s0
7070
table | t1p_tens | unconfined_u:object_r:sepgsql_table_t:s0
7171
column | t1p_tens.o | system_u:object_r:sepgsql_table_t:s0
7272
column | t1p_tens.p | system_u:object_r:sepgsql_ro_table_t:s0

‎contrib/sepgsql/expected/label.out

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,7 @@ SELECT objtype, objname, label FROM pg_seclabels
107107
'tpart',
108108
'tpart_ones',
109109
'tpart_tens')
110-
ORDER BY objname ASC;
110+
ORDER BY objnameCOLLATE "C"ASC;
111111
objtype | objname | label
112112
---------+------------+-----------------------------------------------
113113
table | t1 | unconfined_u:object_r:sepgsql_table_t:s0
@@ -124,7 +124,7 @@ SELECT objtype, objname, label FROM pg_seclabels
124124
OR objname like 'tpart.%'
125125
OR objname like 'tpart_ones.%'
126126
OR objname like 'tpart_tens.%')
127-
ORDER BY objname ASC;
127+
ORDER BY objnameCOLLATE "C"ASC;
128128
objtype | objname | label
129129
---------+---------------------+-----------------------------------------------
130130
column | t3.cmax | unconfined_u:object_r:user_sepgsql_table_t:s0
@@ -147,6 +147,10 @@ SELECT objtype, objname, label FROM pg_seclabels
147147
column | tpart.cmin | unconfined_u:object_r:user_sepgsql_table_t:s0
148148
column | tpart.ctid | unconfined_u:object_r:user_sepgsql_table_t:s0
149149
column | tpart.o | unconfined_u:object_r:user_sepgsql_table_t:s0
150+
column | tpart.p | unconfined_u:object_r:user_sepgsql_table_t:s0
151+
column | tpart.tableoid | unconfined_u:object_r:user_sepgsql_table_t:s0
152+
column | tpart.xmax | unconfined_u:object_r:user_sepgsql_table_t:s0
153+
column | tpart.xmin | unconfined_u:object_r:user_sepgsql_table_t:s0
150154
column | tpart_ones.cmax | unconfined_u:object_r:user_sepgsql_table_t:s0
151155
column | tpart_ones.cmin | unconfined_u:object_r:user_sepgsql_table_t:s0
152156
column | tpart_ones.ctid | unconfined_u:object_r:user_sepgsql_table_t:s0
@@ -155,8 +159,6 @@ SELECT objtype, objname, label FROM pg_seclabels
155159
column | tpart_ones.tableoid | unconfined_u:object_r:user_sepgsql_table_t:s0
156160
column | tpart_ones.xmax | unconfined_u:object_r:user_sepgsql_table_t:s0
157161
column | tpart_ones.xmin | unconfined_u:object_r:user_sepgsql_table_t:s0
158-
column | tpart.p | unconfined_u:object_r:user_sepgsql_table_t:s0
159-
column | tpart.tableoid | unconfined_u:object_r:user_sepgsql_table_t:s0
160162
column | tpart_tens.cmax | unconfined_u:object_r:sepgsql_sysobj_t:s0
161163
column | tpart_tens.cmin | unconfined_u:object_r:sepgsql_sysobj_t:s0
162164
column | tpart_tens.ctid | unconfined_u:object_r:sepgsql_sysobj_t:s0
@@ -165,8 +167,6 @@ SELECT objtype, objname, label FROM pg_seclabels
165167
column | tpart_tens.tableoid | unconfined_u:object_r:sepgsql_sysobj_t:s0
166168
column | tpart_tens.xmax | unconfined_u:object_r:sepgsql_sysobj_t:s0
167169
column | tpart_tens.xmin | unconfined_u:object_r:sepgsql_sysobj_t:s0
168-
column | tpart.xmax | unconfined_u:object_r:user_sepgsql_table_t:s0
169-
column | tpart.xmin | unconfined_u:object_r:user_sepgsql_table_t:s0
170170
(40 rows)
171171

172172
--

‎contrib/sepgsql/sql/dml.sql

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ SELECT objtype, objname, label FROM pg_seclabels
6565
't1p','t1p.o','t1p.p','t1p.q',
6666
't1p_ones','t1p_ones.o','t1p_ones.p','t1p_ones.q',
6767
't1p_tens','t1p_tens.o','t1p_tens.p','t1p_tens.q')
68-
ORDER BY objname;
68+
ORDER BY objname COLLATE"C";
6969

7070
CREATESCHEMAmy_schema_1;
7171
CREATETABLEmy_schema_1.ts1 (aint, btext);

‎contrib/sepgsql/sql/label.sql

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -107,14 +107,14 @@ SELECT objtype, objname, label FROM pg_seclabels
107107
'tpart',
108108
'tpart_ones',
109109
'tpart_tens')
110-
ORDER BY objnameASC;
110+
ORDER BY objnameCOLLATE"C"ASC;
111111
SELECT objtype, objname, labelFROM pg_seclabels
112112
WHERE provider='selinux'AND objtype='column'AND (objnamelike't3.%'
113113
OR objnamelike't4.%'
114114
OR objnamelike'tpart.%'
115115
OR objnamelike'tpart_ones.%'
116116
OR objnamelike'tpart_tens.%')
117-
ORDER BY objnameASC;
117+
ORDER BY objnameCOLLATE"C"ASC;
118118

119119
--
120120
-- Tests for SECURITY LABEL

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp