1
0
mirror of https://github.com/postgres/postgres.git synced 2025-07-30 11:03:19 +03:00

Support retaining data dirs on successful TAP tests

This moves the data directories from using temporary directories with
randomness in the directory name to a static name, to make it easier to
debug.  The data directory will be retained if tests fail or the test
code dies/exits with failure, and is automatically removed on the next
make check.

If the environment variable PG_TEST_NOCLEAN is defined, the data
directories will be retained regardless of test or exit status.

Author: Daniel Gustafsson <daniel@yesql.se>
This commit is contained in:
Peter Eisentraut
2017-09-05 12:22:33 -04:00
parent 5e8304fdce
commit 90627cf98a
7 changed files with 61 additions and 15 deletions

View File

@ -9,13 +9,13 @@ sub run_test
{
my $test_mode = shift;
RewindTest::setup_cluster();
RewindTest::setup_cluster($test_mode);
RewindTest::start_master();
# Create a database in master.
master_psql('CREATE DATABASE inmaster');
RewindTest::create_standby();
RewindTest::create_standby($test_mode);
# Create another database, the creation is replicated to the standby
master_psql('CREATE DATABASE beforepromotion');