#!/usr/bin/perl
BEGIN {
$| = 1;
$^W = 1;
}
my
$client
= HTTP::Client::Parallel->new;
isa_ok(
$client
,
'HTTP::Client::Parallel'
);
if
( 0 ) {
my
$responses
=
$client
->get(
);
warn
Dumper(
$responses
);
}
SCOPE: {
my
$responses
=
$client
->get(
);
is(
ref
(
$responses
),
'ARRAY'
,
'Got an array ref'
);
is(
scalar
(
@$responses
), 1,
'Got a single element'
);
isa_ok(
$responses
->[0],
'HTTP::Response'
);
}
SCOPE: {
my
$responses
= get(
);
is(
ref
(
$responses
),
'ARRAY'
,
'Got an array ref'
);
is(
scalar
(
@$responses
), 1,
'Got a single element'
);
isa_ok(
$responses
->[0],
'HTTP::Response'
);
}