Re: [Perlunit-devel] (no subject)
Status: Beta
Brought to you by:
mca1001
From: Adam S. <ad...@sp...> - 2001-11-15 12:49:18
|
Piers Cawley (pdc...@bo...) wrote: > Adam Spiers <ad...@sp...> writes: > > A nice idea, but surely this wheel has already been invented in some > > way? Why not just do something idiotically simple like sticking the > > test libraries in the `t' directory, and then put > > > > use lib 't'; > > > > in your t/*.t? (Or better, hack Makefile.PL, or god forbid, > > ExtUtils::Makemaker, so that a `make test' includes -It as an option > > when running the tests.) > > Well, it's sort of dependent on where you run the script from. > Actually I'm more inclined to stick the *modules* in t/tlib (I'll > explain why it has to be tlib in a minute) and then do > > use lib 't/tlib', 'tlib'; > > So that you can run the tests from either the project root or from > inside the t directory. It has to be tlib instead of lib to avoid > using the files in lib/* rather than blib/*. Yep, sounds good. It doesn't look like there's any hook in MakeMaker so we could persuade it to add these to @INC directly, hmph. Although doing it that way would break running the tests directly (isn't that deprecated however?) I can do this right now if you want me to. |