mirror of
https://github.com/HypoPG/hypopg
synced 2026-05-24 09:38:21 +00:00
Make tests more portable.
The estimated index size depends on the architecture, so just make sure the code path is tested, without really caring of what the estimated size is. Thanks to Christoph Berg for the report.
This commit is contained in:
parent
386b39912b
commit
73d82eee94
2 changed files with 7 additions and 7 deletions
|
|
@ -95,14 +95,14 @@ FROM public.hypopg_create_index('CREATE INDEX ON hypo(id) WITH (fillfactor = 1)'
|
|||
ERROR: value 1 out of bounds for option "fillfactor"
|
||||
DETAIL: Valid values are between "10" and "100".
|
||||
-- Index size estimation
|
||||
SELECT pg_size_pretty(hypopg_relation_size(indexrelid))
|
||||
SELECT hypopg_relation_size(indexrelid) = current_setting('block_size')::bigint AS one_block
|
||||
FROM hypopg()
|
||||
ORDER BY indexrelid;
|
||||
pg_size_pretty
|
||||
----------------
|
||||
2544 kB
|
||||
8192 bytes
|
||||
4120 kB
|
||||
one_block
|
||||
-----------
|
||||
f
|
||||
t
|
||||
f
|
||||
(3 rows)
|
||||
|
||||
-- locally disable hypoopg
|
||||
|
|
|
|||
|
|
@ -66,7 +66,7 @@ SELECT COUNT(*) AS NB
|
|||
FROM public.hypopg_create_index('CREATE INDEX ON hypo(id) WITH (fillfactor = 1)');
|
||||
|
||||
-- Index size estimation
|
||||
SELECT pg_size_pretty(hypopg_relation_size(indexrelid))
|
||||
SELECT hypopg_relation_size(indexrelid) = current_setting('block_size')::bigint AS one_block
|
||||
FROM hypopg()
|
||||
ORDER BY indexrelid;
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue