File tree Expand file tree Collapse file tree 2 files changed +19
-8
lines changed
Expand file tree Collapse file tree 2 files changed +19
-8
lines changed Original file line number Diff line number Diff line change 1- <!-- $PostgreSQL: pgsql/doc/src/sgml/regress.sgml,v 1.61 2009/02/11 14:03:41 petere Exp $ -->
1+ <!-- $PostgreSQL: pgsql/doc/src/sgml/regress.sgml,v 1.62 2009/02/12 13:26:03 petere Exp $ -->
22
33 <chapter id="regress">
44 <title id="regress-title">Regression Tests</title>
@@ -218,11 +218,15 @@ gmake installcheck
218218 locale-related environment variables on
219219 the <command>make</command> command line, for example:
220220<programlisting>
221- gmake check LC_ALL =de_DE.utf8
221+ gmake check LANG =de_DE.utf8
222222</programlisting>
223- or analogously to use no locale:
223+ (The regression test driver unsets <envar>LC_ALL</envar>, so it
224+ does not work to choose the locale using that variable.) To use
225+ no locale, either unset all locale-related environment variables
226+ (or set them to <literal>C</literal>) or use the following
227+ special invocation:
224228<programlisting>
225- gmake check LC_ALL=C
229+ gmake check NO_LOCALE=1
226230</programlisting>
227231 When running the tests against an existing installation, the
228232 locale setup is determined by the existing installation. To
Original file line number Diff line number Diff line change 1111 * Portions Copyright (c) 1996-2009, PostgreSQL Global Development Group
1212 * Portions Copyright (c) 1994, Regents of the University of California
1313 *
14- * $PostgreSQL: pgsql/src/test/regress/pg_regress.c,v 1.60 2009/02/11 14:03:42 petere Exp $
14+ * $PostgreSQL: pgsql/src/test/regress/pg_regress.c,v 1.61 2009/02/12 13:26:03 petere Exp $
1515 *
1616 *-------------------------------------------------------------------------
1717 */
@@ -694,18 +694,25 @@ initialize_environment(void)
694694 unsetenv ("LC_COLLATE" );
695695 unsetenv ("LC_CTYPE" );
696696 unsetenv ("LC_MONETARY" );
697- unsetenv ("LC_MESSAGES" );
698697 unsetenv ("LC_NUMERIC" );
699698 unsetenv ("LC_TIME" );
700- unsetenv ("LC_ALL" );
701699 unsetenv ("LANG" );
702- unsetenv ("LANGUAGE" );
703700 /* On Windows the default locale cannot be English, so force it */
704701#if defined(WIN32 ) || defined(__CYGWIN__ )
705702 putenv ("LANG=en" );
706703#endif
707704 }
708705
706+ /*
707+ * Set translation-related settings to English; otherwise psql
708+ * will produce translated messages and produce diffs. (XXX If we
709+ * ever support translation of pg_regress, this needs to be moved
710+ * elsewhere, where psql is actually called.)
711+ */
712+ unsetenv ("LANGUAGE" );
713+ unsetenv ("LC_ALL" );
714+ putenv ("LC_MESSAGES=C" );
715+
709716 /*
710717 * Set multibyte as requested
711718 */
You can’t perform that action at this time.
0 commit comments