Skip to content

Commit fe9420a

Browse files
authored
Merge pull request #225 from choroba/tls-error
Allow for a different SSL related error message from the client
2 parents f35f3d6 + 7aa78a5 commit fe9420a

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

t/92ssl_connection.t

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,9 @@ if (defined $dbh) {
2929
ok(defined $cipher, 'SSL connection was established') and diag("mariadb_ssl_cipher is: $cipher");
3030
}
3131
} else {
32-
like($DBI::errstr, qr/^SSL connection error: /, 'DBD::MariaDB supports mariadb_ssl=1 without mariadb_ssl_optional=1 and fail because cannot enforce SSL encryption') or diag('Error message: ' . ($DBI::errstr || 'unknown'));
32+
like($DBI::errstr,
33+
qr{^(?:SSL connection|TLS/SSL) error: },
34+
'DBD::MariaDB supports mariadb_ssl=1 without mariadb_ssl_optional=1 and fail because cannot enforce SSL encryption')
35+
or diag('Error message: ' . ($DBI::errstr || 'unknown'));
3336
is($DBI::err, 2026, 'DBD::MariaDB error code is SSL related') or diag('Error code: ' . ($DBI::err || 'unknown'));
3437
}

0 commit comments

Comments
 (0)