httpd-test-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Stas Bekman <s...@stason.org>
Subject Re: resolving Apache::Test vs. Apache::test collision
Date Tue, 20 May 2003 01:41:04 GMT
David Wheeler wrote:
> On Monday, May 19, 2003, at 05:08  PM, Stas Bekman wrote:
> 
>> That's right. Let's try this next: I've attached a new patch, which 
>> moves the creation of lib/Apache/test.pm into a Makefile.PL. On 
>> case-insensitive systems it'll overwrite lib/Apache/Test.pm.
> 
> 
> That appears to work, but it didn't uninstall the old test.pm, 

So we need to figure out how to enforce UNINST the old Apache/test.pm if any.

For example we could adjust MY::install to unlink it, without messing with 
UNINST=1, though the latter will be the simplest.

> and I 
> haven't tried any tests that use Apache::test using the new one.

I think Geoff's Apache::Clean for mp1 uses it. So does older libapreq.



>> I wish there was a simple test to figure out whether a filesystem is 
>> case-insensitive.
> 
> 
> I think that Perl itself does something like this:
> 
> use File::Spec::Functions qw(catfile);
> 
> my $file = catfile 't', 'TestTest';
> open F, ">$file" or die "Cannot open $file: $!";
> close F;
> my $is_case_insensitive = -e catfile 't', 'testtest';
> unlink $file;

in our case it's then much simpler. Since we don't have lib/Apache/test.pm, we 
can simply test:

my $is_case_insensitive = -e catfile qw(lib Apache test.pm);

>> Also could it possible that under the same OS one partition is 
>> case-insensitive while the other is not? If so, what happens if the 
>> package is built on one but the target is the other?
> 
> 
> Oh, fer cryin' out loud, I don't know. Rename it Apache::Tester and 
> don't worry about it, I say.

Other than the convenience, Apache::Test is used in at least two books 
('mod_perl cookbook', and most likely 'practical mod_perl' too. So it's a 
bummer to have these in Errata if we can find an acceptible workaround.

__________________________________________________________________
Stas Bekman            JAm_pH ------> Just Another mod_perl Hacker
http://stason.org/     mod_perl Guide ---> http://perl.apache.org
mailto:stas@stason.org http://use.perl.org http://apacheweek.com
http://modperlbook.org http://apache.org   http://ticketmaster.com


Mime
View raw message