mirror of
https://github.com/percona/percona-toolkit.git
synced 2025-09-11 21:51:21 +00:00
HTTPMicro: Inline part of IO::Socket::SSL for cases when the local version of the module isn't high enough to support ->verify_hostname(), like in centos5
This commit is contained in:
@@ -20,15 +20,16 @@ if ( $EVAL_ERROR ) {
|
||||
}
|
||||
|
||||
# Need a simple URL that won't try to do chunking.
|
||||
my $test_url = "http://www.percona.com/robots.txt";
|
||||
my $tiny = HTTP::Tiny->new(max_redirect => 0)->request('GET', $test_url);
|
||||
my $micro = HTTPMicro->new->request('GET', $test_url);
|
||||
for my $test_url ( "http://www.percona.com/robots.txt", "https://v.percona.com" ) {
|
||||
my $tiny = HTTP::Tiny->new(max_redirect => 0)->request('GET', $test_url);
|
||||
my $micro = HTTPMicro->new->request('GET', $test_url);
|
||||
|
||||
is_deeply(
|
||||
$micro->{content},
|
||||
$tiny->{content},
|
||||
"HTTPMicro behaves like HTTP::Tiny (max_redirect=0)"
|
||||
);
|
||||
is_deeply(
|
||||
$micro->{content},
|
||||
$tiny->{content},
|
||||
"HTTPMicro behaves like HTTP::Tiny (max_redirect=0)"
|
||||
);
|
||||
}
|
||||
|
||||
done_testing;
|
||||
exit;
|
||||
|
Reference in New Issue
Block a user