Doug MacEachern wrote:

On Wed, 12 Dec 2001, Stas Bekman wrote:


another idea would be to have a second file for this purpose. So if you have foo.t you'd add foo(.t?).conf.in in the same directory with whatever things you want. This is a snap to add (we already scan t/conf for .in files now we can just scan all dirs under t/ recursively.


sure, that would be easy. but would we then have yet another file to implement the CONFIGURE routine? in any case, it would be nice if a .t could be totally self-contained with all three.

agreed, but the other suggestion to check the first line of .t is too restrictive.


Also when you want to get to the CONFIGURE section you have to require() the file, which means it'll run the code in it, which is not good. (compare with .pm, where everything is made of functions).

Also notice that Ken's request is different from what CONFIGURE does. CONFIGURE doesn't add stuff to .conf, the __DATA__ section does. CONFIGURE prepares the environment, creating extra files, etc. So if you want a similarity with .pm, it should go to the __DATA__ section of the .t file too.

_____________________________________________________________________
Stas Bekman             JAm_pH      --   Just Another mod_perl Hacker
http://stason.org/      mod_perl Guide   http://perl.apache.org/guide
mailto:[EMAIL PROTECTED]  http://ticketmaster.com http://apacheweek.com
http://singlesheaven.com http://perl.apache.org http://perlmonth.com/



Reply via email to