|
|
|
@ -7,7 +7,15 @@ use strict; |
|
|
|
|
use warnings; |
|
|
|
|
use PostgresNode; |
|
|
|
|
use TestLib; |
|
|
|
|
use Test::More tests => 12; |
|
|
|
|
use Test::More; |
|
|
|
|
if ($windows_os) |
|
|
|
|
{ |
|
|
|
|
plan skip_all => "authentication tests cannot run on Windows"; |
|
|
|
|
} |
|
|
|
|
else |
|
|
|
|
{ |
|
|
|
|
plan tests => 12; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
# Delete pg_hba.conf from the given node, add a new entry to it |
|
|
|
|
# and then execute a reload to refresh it. |
|
|
|
@ -38,10 +46,6 @@ sub test_login |
|
|
|
|
"authentication $status_string for role $role with password $password"); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
SKIP: |
|
|
|
|
{ |
|
|
|
|
skip "authentication tests cannot run on Windows", 12 if ($windows_os); |
|
|
|
|
|
|
|
|
|
# Initialize master node. Force UTF-8 encoding, so that we can use non-ASCII |
|
|
|
|
# characters in the passwords below. |
|
|
|
|
my $node = get_new_node('master'); |
|
|
|
@ -96,4 +100,3 @@ SKIP: |
|
|
|
|
test_login($node, 'saslpreptest7_role', "foo\xd8\xa71bar", 0); |
|
|
|
|
test_login($node, 'saslpreptest7_role', "foo1\xd8\xa7bar", 2); |
|
|
|
|
test_login($node, 'saslpreptest7_role', "foobar", 2); |
|
|
|
|
} |
|
|
|
|