Re: @INC paths for TAP::Harness

[email protected] (Eric Wilhelm)
Newsgroups perl.module.build
Message-ID <[email protected]>
# from David E. Wheeler
# on Wednesday 09 July 2008 11:58:

>Uh, but DistGen does generate this test:
>
>     use Test::More tests => 1;
>     use strict;
>
>     use $self->{name};
>     ok 1;

Well, I wasn't talking about DistGen and the tests within the tests -- 
just about the tests.

I was looking at including something like this in run_tap_harness()

  my $blib = $self->blib;
  my @inc = map({File::Spec->rel2abs($_)} 
    File::Spec->catdir($self->blib, 'lib'),
    File::Spec->catdir($self->blib, 'arch'),
  );

But alas, like Test::Harness, we have perpetuated a culture of assuming 
that your @INC always magically appears in the child process -- 
including in M::B's own code.  That might be unsurprising most of the 
time, but it does make a certain class of setups relatively impossible.

Anyway, I've decided that doing anything more correct is made of suck 
and would just require me to explain it too often, so I will just be 
foisting @INC into the test.

I'm nearly certain it will break on redhat.

--Eric
-- 
So malloc calls a timeout and starts rummaging around the free chain,
sorting things out, and merging adjacent small free blocks into larger
blocks. This takes 3 1/2 days.
--Joel Spolsky
---------------------------------------------------
    http://scratchcomputing.com
---------------------------------------------------
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.