diff options
| author | Andrew Dunstan <andrew@dunslane.net> | 2021-10-24 10:28:19 -0400 |
|---|---|---|
| committer | Andrew Dunstan <andrew@dunslane.net> | 2021-10-24 10:28:19 -0400 |
| commit | b3b4d8e68ae83f432f43f035c7eb481ef93e1583 (patch) | |
| tree | ff4e73500b61f2235bd4e3822d8e1a1af3a37523 /src/test/modules/libpq_pipeline | |
| parent | 3cd9c3b921977272e6650a5efbeade4203c4bca2 (diff) | |
| download | postgresql-b3b4d8e68ae83f432f43f035c7eb481ef93e1583.tar.gz | |
Move Perl test modules to a better namespace
The five modules in our TAP test framework all had names in the top
level namespace. This is unwise because, even though we're not
exporting them to CPAN, the names can leak, for example if they are
exported by the RPM build process. We therefore move the modules to the
PostgreSQL::Test namespace. In the process PostgresNode is renamed to
Cluster, and TestLib is renamed to Utils. PostgresVersion becomes simply
PostgreSQL::Version, to avoid possible confusion about what it's the
version of.
Discussion: https://postgr.es/m/aede93a4-7d92-ef26-398f-5094944c2504@dunslane.net
Reviewed by Erik Rijkers and Michael Paquier
Diffstat (limited to 'src/test/modules/libpq_pipeline')
| -rw-r--r-- | src/test/modules/libpq_pipeline/t/001_libpq_pipeline.pl | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/test/modules/libpq_pipeline/t/001_libpq_pipeline.pl b/src/test/modules/libpq_pipeline/t/001_libpq_pipeline.pl index 7f648b19a2..4f9b67f254 100644 --- a/src/test/modules/libpq_pipeline/t/001_libpq_pipeline.pl +++ b/src/test/modules/libpq_pipeline/t/001_libpq_pipeline.pl @@ -5,11 +5,11 @@ use strict; use warnings; use Config; -use PostgresNode; -use TestLib; +use PostgreSQL::Test::Cluster; +use PostgreSQL::Test::Utils; use Test::More; -my $node = PostgresNode->new('main'); +my $node = PostgreSQL::Test::Cluster->new('main'); $node->init; $node->start; @@ -19,7 +19,7 @@ my ($out, $err) = run_command([ 'libpq_pipeline', 'tests' ]); die "oops: $err" unless $err eq ''; my @tests = split(/\s+/, $out); -mkdir "$TestLib::tmp_check/traces"; +mkdir "$PostgreSQL::Test::Utils::tmp_check/traces"; for my $testname (@tests) { @@ -29,7 +29,7 @@ for my $testname (@tests) pipeline_abort transaction disallowed_in_pipeline)) > 0; # For a bunch of tests, generate a libpq trace file too. - my $traceout = "$TestLib::tmp_check/traces/$testname.trace"; + my $traceout = "$PostgreSQL::Test::Utils::tmp_check/traces/$testname.trace"; if ($cmptrace) { push @extraargs, "-t", $traceout; |
