postgresql/src/test
Tom Lane d1029bb5a2 Remove dynamic translation of regression test scripts, step 1.
pg_regress has long had provisions for dynamically substituting path
names into regression test scripts and result files, but use of that
feature has always been a serious pain in the neck, mainly because
updating the result files requires tedious manual editing.  Let's
get rid of that in favor of passing down the paths in environment
variables.

In addition to being easier to maintain, this way is capable of
dealing with path names that require escaping at runtime, for example
paths containing single-quote marks.  (There are other stumbling
blocks in the way of actually building in a path that looks like
that, but removing this one seems like a good thing to do.)  The key
coding rule that makes that possible is to concatenate pieces of a
dynamically-variable string using psql's \set command, and then use
the :'variable' notation to quote and escape the string for the next
level of interpretation.

In hopes of making this change more transparent to "git blame",
I've split it into two steps.  This commit adds the necessary
pg_regress.c support and changes all the *.source files in-place
so that they no longer require any dynamic translation.  The next
commit will just "git mv" them into the regular sql/ and expected/
directories.

Discussion: https://postgr.es/m/1655733.1639871614@sss.pgh.pa.us
2021-12-20 14:06:15 -05:00
..
authentication Doc: improve README files associated with TAP tests. 2021-10-31 18:12:44 -04:00
examples libpq: Remove deprecated connection parameters authtype and tty 2021-03-09 15:01:22 +01:00
isolation isolationtester: append session name to application_name. 2021-12-13 12:02:06 -08:00
kerberos Doc: improve README files associated with TAP tests. 2021-10-31 18:12:44 -04:00
ldap Doc: improve README files associated with TAP tests. 2021-10-31 18:12:44 -04:00
locale Remove extraneous newlines added by perl copyright patch 2021-05-07 11:37:37 -04:00
mb
modules Ignore BRIN indexes when checking for HOT udpates 2021-11-30 20:04:38 +01:00
perl Make PG_TEST_USE_UNIX_SOCKETS work for tap tests on windows. 2021-12-13 11:29:51 -08:00
recovery Fix instability in 026_overwrite_contrecord.pl test. 2021-11-09 18:40:19 -05:00
regress Remove dynamic translation of regression test scripts, step 1. 2021-12-20 14:06:15 -05:00
ssl Silence perl complaint in ssl test 2021-12-05 11:50:03 -05:00
subscription Fix double publish of child table's data. 2021-12-09 08:36:59 +05:30
Makefile Revert per-index collation version tracking feature. 2021-05-07 21:10:11 +12:00
README Remove the option to build thread_test.c outside configure. 2020-10-21 12:08:48 -04:00

PostgreSQL tests
================

This directory contains a variety of test infrastructure as well as some of the
tests in PostgreSQL. Not all tests are here -- in particular, there are more in
individual contrib/ modules and in src/bin.

Not all these tests get run by "make check". Check src/test/Makefile to see
which tests get run automatically.

authentication/
  Tests for authentication (but see also below)

examples/
  Demonstration programs for libpq that double as regression tests via
  "make check"

isolation/
  Tests for concurrent behavior at the SQL level

kerberos/
  Tests for Kerberos/GSSAPI authentication and encryption

ldap/
  Tests for LDAP-based authentication

locale/
  Sanity checks for locale data, encodings, etc

mb/
  Tests for multibyte encoding (UTF-8) support

modules/
  Extensions used only or mainly for test purposes, generally not suitable
  for installing in production databases

perl/
  Infrastructure for Perl-based TAP tests

recovery/
  Test suite for recovery and replication

regress/
  PostgreSQL's main regression test suite, pg_regress

ssl/
  Tests to exercise and verify SSL certificate handling

subscription/
  Tests for logical replication