Glenn Linderman wrote:
> 
> 1) why extract it if it could potentially be used in place
> 2) if it cannot be used in place, then why bundle it

I tend to agree.  If they're stored as podified sections, and
get extracted to files, then pod has merely been (mis-)used as
some kind of shar.  

If the test cases are just text until such time as someone
says "execute this test", then they go in the data section.

On the other hand, I've lately been using a certain paradigm
for module unit testing that works like this:

        # Foo.pm
        package Foo;
        #...
        sub unit_test {
                #...
        }
        &unit_test unless caller;
        1;

Then you do

        perl -e Foo.pm

to run the unit test.  And of course, unit_test can be
autoloaded if desired.

-- 
John Porter

        We're building the house of the future together.

Reply via email to