pgsql: Solve cross-version-upgrade testing problem induced by1fb57af92 - Mailing list pgsql-committers

From Tom Lane
Subject pgsql: Solve cross-version-upgrade testing problem induced by1fb57af92
Date
Msg-id E1gseRu-0007kS-Sp@gemulon.postgresql.org
Whole thread Raw
List pgsql-committers
Solve cross-version-upgrade testing problem induced by 1fb57af92.

Renaming varchar_transform to varchar_support had a side effect
I hadn't foreseen: the core regression tests leave around a
transform object that relies on that function, so the name
change breaks cross-version upgrade tests, because the name
used in the older branches doesn't match.

Since the dependency on varchar_transform was chosen with the
aid of a dartboard anyway (it would surely not work as a
language transform support function), fix by just choosing
a different random builtin function with the right signature.
Also add some comments explaining why this isn't horribly unsafe.

I chose to make the same substitution in a couple of other
copied-and-pasted test cases, for consistency, though those
aren't directly contributing to the testing problem.

Per buildfarm.  Back-patch, else it doesn't fix the problem.

Branch
------
REL9_5_STABLE

Details
-------
https://git.postgresql.org/pg/commitdiff/1afcf6aed73997c8beb340195a37cf5939c9eb2e

Modified Files
--------------
src/test/modules/test_ddl_deparse/expected/create_transform.out | 6 ++++--
src/test/modules/test_ddl_deparse/sql/create_transform.sql      | 6 ++++--
src/test/regress/expected/object_address.out                    | 4 +++-
src/test/regress/sql/object_address.sql                         | 4 +++-
4 files changed, 14 insertions(+), 6 deletions(-)


pgsql-committers by date:

Previous
From: Tom Lane
Date:
Subject: pgsql: Repair unsafe/unportable snprintf usage in pg_restore.
Next
From: Andres Freund
Date:
Subject: Re: pgsql: Use better comment marker in Autoconf input