postgresql/src/interfaces/libpq/t/002_api.pl
Bruce Momjian 50e6eb731d Update copyright for 2025
Backpatch-through: 13
2025-01-01 11:21:55 -05:00

22 lines
479 B
Perl

# Copyright (c) 2022-2025, PostgreSQL Global Development Group
use strict;
use warnings FATAL => 'all';
use PostgreSQL::Test::Utils;
use Test::More;
# Test PQsslAttribute(NULL, "library")
my ($out, $err) = run_command([ 'libpq_testclient', '--ssl' ]);
if ($ENV{with_ssl} eq 'openssl')
{
is($out, 'OpenSSL', 'PQsslAttribute(NULL, "library") returns "OpenSSL"');
}
else
{
is( $err,
'SSL is not enabled',
'PQsslAttribute(NULL, "library") returns NULL');
}
done_testing();