Make stats_ext test faster under cache-clobbering test conditions.
authorTom Lane <[email protected]>
Wed, 3 Dec 2025 18:23:45 +0000 (13:23 -0500)
committerTom Lane <[email protected]>
Wed, 3 Dec 2025 18:23:50 +0000 (13:23 -0500)
commit8d61228717e619b90b8ebd1d219d006b920e00e5
treebcec1377dc325d5cdaa98c8fc987edaeea81b3b8
parent7b81be9b42678c7ab69c3e8f565172f1d8d9e86f
Make stats_ext test faster under cache-clobbering test conditions.

Commit 1eccb9315 added a test case that will cause a large number
of evaluations of a plpgsql function.  With -DCLOBBER_CACHE_ALWAYS,
that takes an unreasonable amount of time (hours) because the
function's cache entries are repeatedly deleted and rebuilt.
That doesn't add any useful test coverage --- other test cases
already exercise plpgsql well enough --- and it's not part of what
this test intended to cover.  We can get the same planner coverage,
if not more, by making the test directly invoke numeric_lt().

Reported-by: Tomas Vondra <[email protected]>
Author: Tom Lane <[email protected]>
Discussion: https://postgr.es/m/baf1ae02-83bd-4f5d-872a-1d04f11a9073@vondra.me
src/test/regress/expected/stats_ext.out
src/test/regress/sql/stats_ext.sql