From 51ddb823fbccd9793ac2206288bc9fe5669d3dcb Mon Sep 17 00:00:00 2001 From: tashiro-hisashi Date: Thu, 21 Sep 2023 17:36:52 +0900 Subject: [PATCH] Stabilize regression tests During the AUTOVACUUM regression tests, unintended AUTOVACUUM runs occasionally occurred on unrelated catalogs, notably in pg_collation, causing test failures. Given that the information from theses tables was not crucial for the tests, the check targets are limited to the public schema. (fix #138) --- test/expected/function-logger.out | 9 ++++----- test/script/function-logger.sh | 2 ++ 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/test/expected/function-logger.out b/test/expected/function-logger.out index 86dbaef..1479444 100644 --- a/test/expected/function-logger.out +++ b/test/expected/function-logger.out @@ -68,11 +68,10 @@ DELETE 4001 (1 row) /**--- Collect the AUTOVACUUM information ---**/ - instid | database | schema | table | start | index_scans | page_removed | page_remain | tup_removed | tup_remain | tup_dead | page_hit | page_miss | page_dirty | read_rate | write_rate | duration ---------+-----------+------------+-----------+-------+-------------+--------------+-------------+-------------+------------+----------+----------+-----------+------------+-----------+------------+---------- - 1 | postgres | public | tbl01 | xxx | xxx | xxx | xxx | xxx | xxx | xxx | xxx | xxx | xxx | xxx | xxx | xxx - 1 | template1 | pg_catalog | pg_depend | xxx | xxx | xxx | xxx | xxx | xxx | xxx | xxx | xxx | xxx | xxx | xxx | xxx -(2 rows) + instid | database | schema | table | start | index_scans | page_removed | page_remain | tup_removed | tup_remain | tup_dead | page_hit | page_miss | page_dirty | read_rate | write_rate | duration +--------+----------+--------+-------+-------+-------------+--------------+-------------+-------------+------------+----------+----------+-----------+------------+-----------+------------+---------- + 1 | postgres | public | tbl01 | xxx | xxx | xxx | xxx | xxx | xxx | xxx | xxx | xxx | xxx | xxx | xxx | xxx +(1 row) /**--- Collect the cancelled AUTOVACUUM information ---**/ server signaled diff --git a/test/script/function-logger.sh b/test/script/function-logger.sh index 9376049..227d434 100755 --- a/test/script/function-logger.sh +++ b/test/script/function-logger.sh @@ -243,6 +243,8 @@ SELECT CASE WHEN duration IS NOT NULL THEN 'xxx' END AS duration FROM statsrepo.autovacuum +WHERE + schema = 'public' ORDER BY database, schema, "table"; EOF