@@ -47,7 +47,7 @@ make check
4747<screen>
4848<computeroutput>
4949=======================
50- All 115 tests passed.
50+ All 193 tests passed.
5151=======================
5252</computeroutput>
5353</screen>
@@ -98,7 +98,7 @@ make MAX_CONNECTIONS=10 check
9898
9999 <para>
100100 To run the tests after installation (see <xref linkend="installation"/>),
101- initialize a data area and start the
101+ initialize a data directory and start the
102102 server as explained in <xref linkend="runtime"/>, then type:
103103<screen>
104104make installcheck
@@ -116,10 +116,10 @@ make installcheck-parallel
116116
117117 <para>
118118 The tests will also transiently create some cluster-wide objects, such as
119- roles and tablespaces . These objects will have names beginning with
120- <literal>regress_</literal>. Beware of using <literal>installcheck</literal>
121- mode in installations that have any actual users or tablespaces named
122- that way.
119+ roles, tablespaces, and subscriptions . These objects will have names
120+ beginning with <literal>regress_</literal>. Beware of
121+ using <literal>installcheck</literal> mode with an installation that has
122+ any actual global objects named that way.
123123 </para>
124124 </sect2>
125125
@@ -130,7 +130,7 @@ make installcheck-parallel
130130 The <literal>make check</literal> and <literal>make installcheck</literal> commands
131131 run only the <quote>core</quote> regression tests, which test built-in
132132 functionality of the <productname>PostgreSQL</productname> server. The source
133- distribution also contains additional test suites, most of them having
133+ distribution contains many additional test suites, most of them having
134134 to do with add-on functionality such as optional procedural languages.
135135 </para>
136136
@@ -146,9 +146,24 @@ make installcheck-world
146146 already-installed server, respectively, just as previously explained
147147 for <literal>make check</literal> and <literal>make installcheck</literal>. Other
148148 considerations are the same as previously explained for each method.
149- Note that <literal>make check-world</literal> builds a separate temporary
150- installation tree for each tested module, so it requires a great deal
151- more time and disk space than <literal>make installcheck-world</literal>.
149+ Note that <literal>make check-world</literal> builds a separate instance
150+ (temporary data directory) for each tested module, so it requires more
151+ time and disk space than <literal>make installcheck-world</literal>.
152+ </para>
153+
154+ <para>
155+ On a modern machine with multiple CPU cores and no tight operating-system
156+ limits, you can make things go substantially faster with parallelism.
157+ The recipe that most PostgreSQL developers actually use for running all
158+ tests is something like
159+ <screen>
160+ make check-world -j8 >/dev/null
161+ </screen>
162+ with a <option>-j</option> limit near to or a bit more than the number
163+ of available cores. Discarding <systemitem>stdout</systemitem>
164+ eliminates chatter that's not interesting when you just want to verify
165+ success. (In case of failure, the <systemitem>stderr</systemitem>
166+ messages are usually enough to determine where to look closer.)
152167 </para>
153168
154169 <para>
@@ -166,8 +181,7 @@ make installcheck-world
166181 <itemizedlist>
167182 <listitem>
168183 <para>
169- Regression tests for optional procedural languages (other than
170- <application>PL/pgSQL</application>, which is tested by the core tests).
184+ Regression tests for optional procedural languages.
171185 These are located under <filename>src/pl</filename>.
172186 </para>
173187 </listitem>
@@ -184,6 +198,13 @@ make installcheck-world
184198 located in <filename>src/interfaces/ecpg/test</filename>.
185199 </para>
186200 </listitem>
201+ <listitem>
202+ <para>
203+ Tests for core-supported authentication methods,
204+ located in <filename>src/test/authentication</filename>.
205+ (See below for additional authentication-related tests.)
206+ </para>
207+ </listitem>
187208 <listitem>
188209 <para>
189210 Tests stressing behavior of concurrent sessions,
@@ -192,21 +213,36 @@ make installcheck-world
192213 </listitem>
193214 <listitem>
194215 <para>
195- Tests of client programs under <filename>src/bin</filename>. See
196- also <xref linkend="regress-tap"/>.
216+ Tests for crash recovery and physical replication,
217+ located in <filename>src/test/recovery</filename>.
218+ </para>
219+ </listitem>
220+ <listitem>
221+ <para>
222+ Tests for logical replication,
223+ located in <filename>src/test/subscription</filename>.
224+ </para>
225+ </listitem>
226+ <listitem>
227+ <para>
228+ Tests of client programs, located under <filename>src/bin</filename>.
197229 </para>
198230 </listitem>
199231 </itemizedlist>
200232
201233 <para>
202- When using <literal>installcheck</literal> mode, these tests will destroy any
203- existing databases named <literal>pl_regression</literal>,
204- <literal>contrib_regression</literal>, <literal>isolation_regression</literal>,
205- <literal>ecpg1_regression</literal>, or <literal>ecpg2_regression</literal>, as well as
206- <literal>regression</literal>.
234+ When using <literal>installcheck</literal> mode, these tests will create
235+ and destroy test databases whose names
236+ include <literal>regression</literal>, for
237+ example <literal>pl_regression</literal>
238+ or <literal>contrib_regression</literal>. Beware of
239+ using <literal>installcheck</literal> mode with an installation that has
240+ any non-test databases named that way.
207241 </para>
208242
209243 <para>
244+ Some of these auxiliary test suites use the TAP infrastructure explained
245+ in <xref linkend="regress-tap"/>.
210246 The TAP-based tests are run only when PostgreSQL was configured with the
211247 option <option>--enable-tap-tests</option>. This is recommended for
212248 development, but can be omitted if there is no suitable Perl installation.
@@ -259,6 +295,17 @@ make check-world PG_TEST_EXTRA='kerberos ldap ssl'
259295 configuration are not run even if they are mentioned in
260296 <varname>PG_TEST_EXTRA</varname>.
261297 </para>
298+
299+ <para>
300+ In addition, there are tests in <filename>src/test/modules</filename>
301+ which will be run by <literal>make check-world</literal> but not
302+ by <literal>make installcheck-world</literal>. This is because they
303+ install non-production extensions or have other side-effects that are
304+ considered undesirable for a production installation. You can
305+ use <literal>make install</literal> and <literal>make
306+ installcheck</literal> in one of those subdirectories if you wish,
307+ but it's not recommended to do so with a non-test server.
308+ </para>
262309 </sect2>
263310
264311 <sect2>
@@ -737,6 +784,26 @@ make check PROVE_TESTS='t/001_test1.pl t/003_test3.pl'
737784 The TAP tests require the Perl module <literal>IPC::Run</literal>.
738785 This module is available from CPAN or an operating system package.
739786 </para>
787+
788+ <para>
789+ Generically speaking, the TAP tests will test the executables in a
790+ previously-installed installation tree if you say <literal>make
791+ installcheck</literal>, or will build a new local installation tree from
792+ current sources if you say <literal>make check</literal>. In either
793+ case they will initialize a local instance (data directory) and
794+ transiently run a server in it. Some of these tests run more than one
795+ server. Thus, these tests can be fairly resource-intensive.
796+ </para>
797+
798+ <para>
799+ It's important to realize that the TAP tests will start test server(s)
800+ even when you say <literal>make installcheck</literal>; this is unlike
801+ the traditional non-TAP testing infrastructure, which expects to use an
802+ already-running test server in that case. Some PostgreSQL
803+ subdirectories contain both traditional-style and TAP-style tests,
804+ meaning that <literal>make installcheck</literal> will produce a mix of
805+ results from temporary servers and the already-running test server.
806+ </para>
740807 </sect1>
741808
742809 <sect1 id="regress-coverage">
0 commit comments