pgsql: Fix two portability issues with the tests of test_oat_hooks

Поиск
Список
Период
Сортировка
От Michael Paquier
Тема pgsql: Fix two portability issues with the tests of test_oat_hooks
Дата
Msg-id E1oAkPG-002DJi-Ro@gemulon.postgresql.org
обсуждение исходный текст
Список pgsql-committers
Fix two portability issues with the tests of test_oat_hooks

This addresses two issues in the tests of test_oat_hooks:
- The role regress_test_user was being left behind, preventing the test
to succeed on repeated runs.  It makes sense to leave some objects
behind to have more coverage for pg_upgrade (as does test_pg_dump), but
the role dropped here does not own any objects so there is no reason to
keep it.
- GRANT SET ON PARAMETER is issued, creating an entry in
pg_parameter_acl without cleaning up the entry created.  This causes
an overlap with unsafe_tests as both use work_mem, making the latter
fail.  This commit adds an extra REVOKE SET ON PARAMETER to clean the
contents of pg_parameter_acl, switching to maintenance_work_mem rather
than work_mem to avoid an overlap between both tests.

The tests of test_oat_hooks cannot use installcheck yet as these are
proving to be unstable with caching and the namespace search hooks, so
the issues fixed here cannot be reached yet, but they would be once the
hook issue is addressed and installcheck is allowed again in
test_oat_hooks.

Discussion: https://postgr.es/m/YrpVkADAY0knF6vM@paquier.xyz
Backpatch-through: 15

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/a6434b951558baad8372dc4b83bf87606dac9cda

Modified Files
--------------
src/test/modules/test_oat_hooks/expected/test_oat_hooks.out | 8 ++++++--
src/test/modules/test_oat_hooks/sql/test_oat_hooks.sql      | 6 ++++--
2 files changed, 10 insertions(+), 4 deletions(-)


В списке pgsql-committers по дате отправления:

Предыдущее
От: Michael Paquier
Дата:
Сообщение: pgsql: Improve error message with JSON_SERIALIZE()
Следующее
От: Michael Paquier
Дата:
Сообщение: Re: pgsql: Only allow returning string types or bytea from json_serialize