mirror of
https://github.com/postgres/postgres.git
synced 2025-07-28 23:42:10 +03:00
Fix entirely broken permissions test in new alter_operator regression test.
Not only did this test fail to test what it was supposed to test, but it left a user definition lying around, which caused subsequent runs of the regression tests to fail.
This commit is contained in:
@ -66,11 +66,10 @@ ERROR: operator attribute "negator" can not be changed
|
|||||||
-- Test permission check. Must be owner to ALTER OPERATOR.
|
-- Test permission check. Must be owner to ALTER OPERATOR.
|
||||||
--
|
--
|
||||||
CREATE USER regtest_alter_user;
|
CREATE USER regtest_alter_user;
|
||||||
SET SESSION AUTHORIZATION regtest_alter_user_user;
|
SET SESSION AUTHORIZATION regtest_alter_user;
|
||||||
ERROR: role "regtest_alter_user_user" does not exist
|
|
||||||
ALTER OPERATOR === (boolean, boolean) SET (RESTRICT = NONE);
|
ALTER OPERATOR === (boolean, boolean) SET (RESTRICT = NONE);
|
||||||
RESET SESSION AUTHORIZATION;
|
ERROR: must be owner of operator ===
|
||||||
-- Clean up
|
-- Clean up
|
||||||
DROP USER regression_alter_user;
|
RESET SESSION AUTHORIZATION;
|
||||||
ERROR: role "regression_alter_user" does not exist
|
DROP USER regtest_alter_user;
|
||||||
DROP OPERATOR === (boolean, boolean);
|
DROP OPERATOR === (boolean, boolean);
|
||||||
|
@ -48,17 +48,15 @@ ALTER OPERATOR === (boolean, boolean) SET (JOIN = non_existent_func);
|
|||||||
ALTER OPERATOR === (boolean, boolean) SET (COMMUTATOR = !==);
|
ALTER OPERATOR === (boolean, boolean) SET (COMMUTATOR = !==);
|
||||||
ALTER OPERATOR === (boolean, boolean) SET (NEGATOR = !==);
|
ALTER OPERATOR === (boolean, boolean) SET (NEGATOR = !==);
|
||||||
|
|
||||||
|
|
||||||
--
|
--
|
||||||
-- Test permission check. Must be owner to ALTER OPERATOR.
|
-- Test permission check. Must be owner to ALTER OPERATOR.
|
||||||
--
|
--
|
||||||
CREATE USER regtest_alter_user;
|
CREATE USER regtest_alter_user;
|
||||||
SET SESSION AUTHORIZATION regtest_alter_user_user;
|
SET SESSION AUTHORIZATION regtest_alter_user;
|
||||||
|
|
||||||
ALTER OPERATOR === (boolean, boolean) SET (RESTRICT = NONE);
|
ALTER OPERATOR === (boolean, boolean) SET (RESTRICT = NONE);
|
||||||
|
|
||||||
RESET SESSION AUTHORIZATION;
|
|
||||||
|
|
||||||
-- Clean up
|
-- Clean up
|
||||||
DROP USER regression_alter_user;
|
RESET SESSION AUTHORIZATION;
|
||||||
|
DROP USER regtest_alter_user;
|
||||||
DROP OPERATOR === (boolean, boolean);
|
DROP OPERATOR === (boolean, boolean);
|
||||||
|
Reference in New Issue
Block a user