httpd-test-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Stas Bekman <>
Subject Re: need help to add per-user config to Apache::Test
Date Wed, 03 Sep 2003 17:52:01 GMT
Randy Kobes wrote:
> On Tue, 2 Sep 2003, Stas Bekman wrote:
>>Randy Kobes wrote:
> [ .. ]
>>Very good, a few more comments following
>> > +    $self->write_config() if
>>probably better to do that right after $self->configure is
>>completed, as the very last thing in:
> OK - this is done in the diff at the end. For this, to
> override a setting within Apache::TestConfigData from some
> external package, one has to do
>    t/TEST -config -save -httpd /usr/local/httpd/bin/httpd

It should work during 'make test' as well, since it already runs t/TEST 
-config. And also whenever you provide any options to t/TEST it reconfigures, 
so I believe the normal run will do the same:

  t/TEST -save -httpd /usr/local/httpd/bin/httpd

I haven't tested that though.

>>>+    my $file = catfile($dir, '');
>>>+    unless (open($fh, ">$file")) {
>>>+        warn "Cannot open $file: $!";
>>>+        return;
>>>+    }
> [ .. ]
>>Ahm, so you write that file twice if inside the
>>Apache-Test build dir because Makefile.PL has been run
>>long time ago. We will have problems with MakeMaker
>>picking this file for 'make install', so we must provide a
>>placeholder for that file. I suppose
>>Apache/ always needs to be in the
>>distribution but include an empty:
>>   $Apache::TestConfigData = {};
>>So now instead of trying to eval {} for the module in @_
>>we can simply require it, and then test whether
>>%$Apache::TestConfigData has something in it?
> Good idea - that's much simpler. The following assumes
> that an empty Apache/ is present, and
> then, as you say, 'make install' will pick up any changes
> that have been made to it.

If I remember correctly 'make install' will complain about the mismatch in 
sizes since 'make' has already put the files into blib? Did it work for you 
just fine? Purhaps we do need to update the two.

Otherwise looks good ;)

Stas Bekman            JAm_pH ------> Just Another mod_perl Hacker     mod_perl Guide --->

View raw message