httpd-test-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From David Wheeler <>
Subject Re: cvs commit: httpd-test/perl-framework/Apache-Test/lib/Apache
Date Tue, 26 Oct 2004 01:47:12 GMT
On Oct 25, 2004, at 4:33 PM, Geoffrey Young wrote:

> let's give david a chance to investigate - either to fix or, if a 
> quick fix
> isn't obvious, revert the behavior.
> if david doesn't respond by, say, wednesday, we (you or I) should feel 
> free
> to just revert the change.  maybe david is on vacation or something, 
> or just
> temporarily behind in his emails.

No, just hacking. Let's see...oh, I get it. I changed it so that it 
ignored $RedirectOK if LWP was installed. That's not necessarily a good 
idea, given the goofy way in which this module is written. I've applied 
a fix to only let LWP handle the call to redirect_ok() if a an array 
reference was passed to user_agent( requests_redirectable => []). Ugh, 
that is so ugly!

But this doesn't seem to help t/ssl/basicauth.t. But even if I roll 
back the changes that test still fails, so I'm inclined to think that 
it's failing for some other reason.

You know, I'm inclined to remove that stupid $RedirectOK global 
variable, because you can't tell whether it was set by the user of 
Apache::TestRequest. This makes it difficult to decide whether or not 
to let LWP handle the call to redirect_ok(). What say you all to my 
changing this to a class method, say RedirectOK()? Then it can be 
smarter about who is doing what to whom. It would require I change the 
tests that rely on it, but they don't appear to be too many:

% grep -r RedirectOK t
t/modules/alias.t:    local $Apache::TestRequest::RedirectOK = 0;
t/modules/alias.t:    local $Apache::TestRequest::RedirectOK = 0;
t/ssl/proxy.t:        local $Apache::TestRequest::RedirectOK = 0;




View raw message