The test targets libpq's options, so 'src/test/interfaces/libpq/t' is
a more natural place for it.
While doing this, I noticed that I had missed adding the
libpq_encryption subdir to the Makefile. That's why this commit only
needs to remove it from the meson.build file.
Per Peter Eisentraut's suggestion.
Discussion: https://www.postgresql.org/message-id/
09d4bf5d-d0fa-4c66-a1d7-
5ec757609646@eisentraut.org
top_builddir = ../../..
include $(top_builddir)/src/Makefile.global
-export with_ssl
+export with_ssl with_gssapi with_krb_srvnam
PGFILEDESC = "PostgreSQL Access Library"
't/002_api.pl',
't/003_load_balance_host_list.pl',
't/004_load_balance_dns.pl',
+ 't/005_negotiate_encryption.pl',
],
- 'env': {'with_ssl': ssl_library},
+ 'env': {
+ 'with_ssl': ssl_library,
+ 'with_gssapi': gssapi.found() ? 'yes' : 'no',
+ 'with_krb_srvnam': 'postgres',
+ },
},
}
if ($ssl_supported != 0)
{
- my $certdir = dirname(__FILE__) . "/../../ssl/ssl";
+ my $certdir = dirname(__FILE__) . "/../../../test/ssl/ssl";
copy "$certdir/server-cn-only.crt", "$pgdata/server.crt"
|| die "copying server.crt: $!";
+++ /dev/null
-#-------------------------------------------------------------------------
-#
-# Makefile for src/test/libpq_encryption
-#
-# Portions Copyright (c) 1996-2024, PostgreSQL Global Development Group
-# Portions Copyright (c) 1994, Regents of the University of California
-#
-# src/test/libpq_encryption/Makefile
-#
-#-------------------------------------------------------------------------
-
-subdir = src/test/libpq_encryption
-top_builddir = ../../..
-include $(top_builddir)/src/Makefile.global
-
-export with_ssl with_gssapi with_krb_srvnam
-
-check:
- $(prove_check)
-
-installcheck:
- $(prove_installcheck)
-
-clean distclean:
- rm -rf tmp_check
+++ /dev/null
-src/test/libpq_encryption/README
-
-Tests for negotiating network encryption method
-===============================================
-
-This directory contains a test suite for the libpq options to
-negotiate encryption with the server. This requires reconfiguring a
-test server, enabling/disabling SSL and GSSAPI, and is therefore kept
-separate and not run by default.
-
-CAUTION: The test server run by this test is configured to listen for TCP
-connections on localhost. Any user on the same host is able to log in to the
-test server while the tests are running. Do not run this suite on a multi-user
-system where you don't trust all local users! Also, this test suite creates a
-KDC server that listens for TCP/IP connections on localhost without any real
-access control.
-
-Running the tests
-=================
-
-NOTE: You must have given the --enable-tap-tests argument to configure.
-
-Run
- make check PG_TEST_EXTRA=libpq_encryption
-
-You can use "make installcheck" if you previously did "make install".
-In that case, the code in the installation tree is tested. With
-"make check", a temporary installation tree is built from the current
-sources and then tested.
-
-See src/test/perl/README for more info about running these tests.
+++ /dev/null
-# Copyright (c) 2022-2024, PostgreSQL Global Development Group
-
-tests += {
- 'name': 'libpq_encryption',
- 'sd': meson.current_source_dir(),
- 'bd': meson.current_build_dir(),
- 'tap': {
- 'tests': [
- 't/001_negotiate_encryption.pl',
- ],
- 'env': {
- 'with_ssl': ssl_library,
- 'OPENSSL': openssl.found() ? openssl.path() : '',
- 'with_gssapi': gssapi.found() ? 'yes' : 'no',
- 'with_krb_srvnam': 'postgres',
- },
- },
-}
subdir('isolation')
subdir('authentication')
-subdir('libpq_encryption')
subdir('recovery')
subdir('subscription')
subdir('modules')