postgresql/src/test
Michael Paquier 72f92549b6 Fix random regression failure in test case "temp"
This test case could fail because of an incorrect result ordering when
looking up at pg_class entries.  This commit adds an ORDER BY to the
culprit query.  The cause of the failure was likely caused by a plan
switch.  By default, the planner would likely choose an index-only scan
or an index scan, but even a small change in the startup cost could have
caused a bitmap heap scan to be chosen, causing the failure.

While on it, switch some filtering quals to a regular expression as per
an idea of Tom Lane.  As previously shaped, the quals would have
selected any relations whose name begins with "temp".  And that could
cause failures if another test running in parallel began to use similar
relation names.

Per report from buildfarm member anole, though the failure was very
rare.  This test has been introduced by 319a810, so backpatch down to
v10.

Discussion: https://postgr.es/m/20190807132422.GC15695@paquier.xyz
Backpatch-through: 10
2019-08-13 10:56:02 +09:00
..
authentication Clarify the README files for the various separate TAP-based test suites. 2018-06-19 19:30:50 -04:00
examples Client-side fixes for delayed NOTIFY receipt. 2018-10-19 22:22:57 -04:00
isolation Fix predicate-locking of HOT updated rows. 2019-08-07 12:41:16 +03:00
kerberos Save Kerberos and LDAP daemon logs where the buildfarm can find them. 2019-08-06 17:08:38 -04:00
ldap Fix certificate subjects in ldap test 2019-08-08 15:02:25 -04:00
locale Add a temp-install prerequisite to "check"-like targets not having one. 2017-11-05 18:51:08 -08:00
mb Fix MB regression tests for WAL-logging of hash indexes. 2017-03-15 07:25:36 -04:00
modules Adjust error message 2019-02-11 10:31:36 +01:00
perl Avoid picking already-bound TCP ports in kerberos and ldap test suites. 2019-08-04 13:07:12 -04:00
recovery Fix failure with pgperlcritic from the TAP test of synchronous replication 2019-07-25 07:55:33 +09:00
regress Fix random regression failure in test case "temp" 2019-08-13 10:56:02 +09:00
ssl Hack back-branch SSL tests to avoid intermittent buildfarm failures. 2019-03-19 16:58:20 -04:00
subscription Fix handling of temp and unlogged tables in FOR ALL TABLES publications 2019-04-18 08:56:32 +02:00
thread Update copyright for 2018 2018-01-02 23:30:12 -05:00
Makefile Revert "Allow on-line enabling and disabling of data checksums" 2018-04-09 19:03:42 +02:00
README Add TAP tests for password-based authentication methods. 2017-03-17 11:34:16 +02: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

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

isolation/
  Tests for concurrent behavior at the SQL level

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

thread/
  A thread-safety-testing utility used by configure