Don't leave roles behind after core regression tests.
Commits cf5eb37c5 and e5b8a4c09 each created a new role that they forgot to remove again. This breaks the use-case of running "make installcheck" more than once, and it's also against project policy because it'd be quite unfriendly behavior if one were running "make installcheck" against a non-throwaway installation.
This commit is contained in:
parent
c971a5b27a
commit
d0d9683287
@ -174,18 +174,23 @@ DROP ROLE regress_password_null;
|
|||||||
DROP ROLE regress_noiseword;
|
DROP ROLE regress_noiseword;
|
||||||
DROP ROLE regress_inroles;
|
DROP ROLE regress_inroles;
|
||||||
DROP ROLE regress_adminroles;
|
DROP ROLE regress_adminroles;
|
||||||
-- fail, cannot drop ourself nor superusers
|
-- fail, cannot drop ourself, nor superusers or roles we lack ADMIN for
|
||||||
DROP ROLE regress_role_super;
|
DROP ROLE regress_role_super;
|
||||||
ERROR: must be superuser to drop superusers
|
ERROR: must be superuser to drop superusers
|
||||||
DROP ROLE regress_role_admin;
|
DROP ROLE regress_role_admin;
|
||||||
ERROR: current user cannot be dropped
|
ERROR: current user cannot be dropped
|
||||||
|
DROP ROLE regress_rolecreator;
|
||||||
|
ERROR: must have admin option on role "regress_rolecreator"
|
||||||
-- ok
|
-- ok
|
||||||
RESET SESSION AUTHORIZATION;
|
RESET SESSION AUTHORIZATION;
|
||||||
REVOKE CREATE ON DATABASE regression FROM regress_role_admin CASCADE;
|
REVOKE CREATE ON DATABASE regression FROM regress_role_admin CASCADE;
|
||||||
DROP INDEX tenant_idx;
|
DROP INDEX tenant_idx;
|
||||||
DROP TABLE tenant_table;
|
DROP TABLE tenant_table;
|
||||||
DROP VIEW tenant_view;
|
DROP VIEW tenant_view;
|
||||||
|
DROP SCHEMA regress_tenant2_schema;
|
||||||
DROP ROLE regress_tenant;
|
DROP ROLE regress_tenant;
|
||||||
|
DROP ROLE regress_tenant2;
|
||||||
|
DROP ROLE regress_rolecreator;
|
||||||
DROP ROLE regress_role_admin;
|
DROP ROLE regress_role_admin;
|
||||||
DROP ROLE regress_role_super;
|
DROP ROLE regress_role_super;
|
||||||
DROP ROLE regress_role_normal;
|
DROP ROLE regress_role_normal;
|
||||||
|
@ -161,9 +161,10 @@ DROP ROLE regress_noiseword;
|
|||||||
DROP ROLE regress_inroles;
|
DROP ROLE regress_inroles;
|
||||||
DROP ROLE regress_adminroles;
|
DROP ROLE regress_adminroles;
|
||||||
|
|
||||||
-- fail, cannot drop ourself nor superusers
|
-- fail, cannot drop ourself, nor superusers or roles we lack ADMIN for
|
||||||
DROP ROLE regress_role_super;
|
DROP ROLE regress_role_super;
|
||||||
DROP ROLE regress_role_admin;
|
DROP ROLE regress_role_admin;
|
||||||
|
DROP ROLE regress_rolecreator;
|
||||||
|
|
||||||
-- ok
|
-- ok
|
||||||
RESET SESSION AUTHORIZATION;
|
RESET SESSION AUTHORIZATION;
|
||||||
@ -171,7 +172,10 @@ REVOKE CREATE ON DATABASE regression FROM regress_role_admin CASCADE;
|
|||||||
DROP INDEX tenant_idx;
|
DROP INDEX tenant_idx;
|
||||||
DROP TABLE tenant_table;
|
DROP TABLE tenant_table;
|
||||||
DROP VIEW tenant_view;
|
DROP VIEW tenant_view;
|
||||||
|
DROP SCHEMA regress_tenant2_schema;
|
||||||
DROP ROLE regress_tenant;
|
DROP ROLE regress_tenant;
|
||||||
|
DROP ROLE regress_tenant2;
|
||||||
|
DROP ROLE regress_rolecreator;
|
||||||
DROP ROLE regress_role_admin;
|
DROP ROLE regress_role_admin;
|
||||||
DROP ROLE regress_role_super;
|
DROP ROLE regress_role_super;
|
||||||
DROP ROLE regress_role_normal;
|
DROP ROLE regress_role_normal;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user