X-Git-Url: http://git.indexdata.com/?a=blobdiff_plain;f=t%2F1-Net-Z3950-ZOOM.t;h=1e85894cd1f7ec7c3ee62409626551e7375f4ae6;hb=e19515ab18d8e5002b39536d9d27ed7243eb4e64;hp=d53014597a6ce4bfb78daa5d44f982541bb7e28a;hpb=beda31b7cd0715d4830891459f75f5ddff416489;p=ZOOM-Perl-moved-to-github.git diff --git a/t/1-Net-Z3950-ZOOM.t b/t/1-Net-Z3950-ZOOM.t index d530145..1e85894 100644 --- a/t/1-Net-Z3950-ZOOM.t +++ b/t/1-Net-Z3950-ZOOM.t @@ -19,8 +19,10 @@ my($errcode, $errmsg, $addinfo) = (undef, "dummy", "dummy"); my $host = "no.such.host"; my $conn = Net::Z3950::ZOOM::connection_new($host, 0); $errcode = Net::Z3950::ZOOM::connection_error($conn, $errmsg, $addinfo); -ok($errcode == Net::Z3950::ZOOM::ERROR_CONNECT && $addinfo eq $host, - "connection to non-existent host '$host' fails"); +# For some reason, Red Hat signals this as a TIMEOUT rather than a CONNECT +ok(($errcode == Net::Z3950::ZOOM::ERROR_CONNECT && $addinfo eq $host) || + ($errcode == Net::Z3950::ZOOM::ERROR_TIMEOUT && $addinfo eq ""), + "connection to non-existent host '$host' fails: errcode=$errcode, addinfo=$addinfo"); $host = "z3950.indexdata.com/gils"; $conn = Net::Z3950::ZOOM::connection_new($host, 0);