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

Commit6928484

Browse files
committed
GRANT rights to CURRENT_USER instead of adding roles
We shouldn't be adding roles during the regression tests as that cancause back-to-back installcheck runs to fail and users running theregression tests likley don't want those extra roles.Pointed out by Tom
1 parent3308467 commit6928484

File tree

2 files changed

+7
-9
lines changed

2 files changed

+7
-9
lines changed

‎src/test/regress/expected/init_privs.out

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,7 @@ SELECT count(*) > 0 FROM pg_init_privs;
66
t
77
(1 row)
88

9-
CREATE ROLE init_privs_test_role1;
10-
CREATE ROLE init_privs_test_role2;
119
-- Intentionally include some non-initial privs for pg_dump to dump out
12-
GRANT SELECT ON pg_proc TO init_privs_test_role1;
13-
GRANT SELECT (prosrc) ON pg_proc TO init_privs_test_role2;
10+
GRANT SELECT ON pg_proc TO CURRENT_USER;
11+
GRANT SELECT (prosrc) ON pg_proc TO CURRENT_USER;
12+
GRANT SELECT (rolname, rolsuper) ON pg_authid TO CURRENT_USER;

‎src/test/regress/sql/init_privs.sql

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,8 @@
33
-- There should always be some initial privileges, set up by initdb
44
SELECTcount(*)>0FROM pg_init_privs;
55

6-
CREATE ROLE init_privs_test_role1;
7-
CREATE ROLE init_privs_test_role2;
8-
96
-- Intentionally include some non-initial privs for pg_dump to dump out
10-
GRANTSELECTON pg_proc TO init_privs_test_role1;
11-
GRANTSELECT (prosrc)ON pg_proc TO init_privs_test_role2;
7+
GRANTSELECTON pg_proc TOCURRENT_USER;
8+
GRANTSELECT (prosrc)ON pg_proc TOCURRENT_USER;
9+
10+
GRANTSELECT (rolname, rolsuper)ON pg_authid TOCURRENT_USER;

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp