Date: | Wed, 23 Jul 2003 18:26:14 +1000 |
To: | bug-www-mechanize [...] rt.cpan.org |
Subject: | t/failure.t failure with proxies |
From: | Iain Truskett <spoon [...] cpan.org> |
Heyo,
My web access ostensibly goes through a proxy. Your tests certainly do.
The problem is that if the _proxy_ can't find a page it does return HTML
and it does return HTML with a title and some links.
Thus tests 12, 13 and 14 of failure.t fail to fail.
Sticking a "warn $a->content;" into failure.t gives the output
seen below my sig.
cheers,
--
iain. <http://eh.org/~koschei/>
__DATA__
1..15
ok 1 - use WWW::Mechanize;
ok 2 - Created object isa WWW::Mechanize
ok 3 - The object isa HTTP::Response
ok 4 - Success
ok 5 - Get webpage
ok 6 - Set uri isa URI
ok 7 - It's HTML
ok 8 - Correct title
ok 9 - eight links, please
ok 10 - One form
<HTML><HEAD>
<TITLE>ERROR: The requested URL could not be retrieved</TITLE>
</HEAD><BODY>
<H2>The requested URL could not be retrieved</H2>
<HR>
<P>
While trying to retrieve the URL:
<A HREF="http://sdlfkjsdlfjks.blofgorongotron.com">http://sdlfkjsdlfjks.blofgorongotron.com</A>
<P>
The following error was encountered:
<BLOCKQUOTE>
Unable to determine IP address from host name for
<I>sdlfkjsdlfjks.blofgorongotron.com</I>
</BLOCKQUOTE>
<P>
The dnsserver returned:
<BLOCKQUOTE>
Name Error: The domain name does not exist.
</BLOCKQUOTE>
<P>
This means that:
<PRE>
The cache was not able to resolve the hostname presented in the URL.
Check if the address is correct.
</PRE>
<P>Your cache administrator is <A HREF="mailto:root">root</A>.
<br clear="all">
<hr noshade size=1>
Generated Wed, 23 Jul 2003 08:22:10 GMT by ouroboros.anu.edu.au (Squid/2.4.STABLE6)
</BODY></HTML>
ok 11 - Failed the fetch
not ok 12 - Isn't HTML
# Failed test (t/failure.t at line 37)
not ok 13 - No title
# Failed test (t/failure.t at line 38)
not ok 14 - No links
# Failed test (t/failure.t at line 41)
# got: '2'
# expected: '0'
ok 15 - No forms
# Looks like you failed 3 tests of 15.