mirror of
https://github.com/postgres/postgres.git
synced 2025-07-31 22:04:40 +03:00
Allow TAP tests to force checksums off when calling init()
TAP tests can write $node->init(no_data_checksums => 1); to initialize a cluster explicitly without checksums. Currently, this is the default, but this change allows running all tests with checksums enabled, like PG_TEST_INITDB_EXTRA_OPTS=--data-checksums meson test ... And this also prepares the tests for when we switch the default to checksums enabled. The pg_checksums tests need to disable checksums so it can test its own functionality of enabling checksums. The amcheck/pg_amcheck tests need to disable checksums because they manually introduce corruption that they want to detect, but with checksums enabled, the checksum verification will fail before they even get to their work. Author: Greg Sabino Mullane <greg@turnstep.com> Reviewed-by: Nathan Bossart <nathandbossart@gmail.com> Reviewed-by: Peter Eisentraut <peter@eisentraut.org> Discussion: https://www.postgresql.org/message-id/flat/CAKAnmmKwiMHik5AHmBEdf5vqzbOBbcwEPHo4-PioWeAbzwcTOQ@mail.gmail.com
This commit is contained in:
@ -15,7 +15,7 @@ my $node;
|
||||
# Test set-up
|
||||
#
|
||||
$node = PostgreSQL::Test::Cluster->new('test');
|
||||
$node->init;
|
||||
$node->init(no_data_checksums => 1);
|
||||
$node->append_conf('postgresql.conf', 'autovacuum=off');
|
||||
$node->start;
|
||||
$node->safe_psql('postgres', q(CREATE EXTENSION amcheck));
|
||||
|
Reference in New Issue
Block a user