Carletto wrote: > Hi! > Anyone has experience in testing an Apache module (mod_perl 2.0, of course) > with > custom configuration directives ? > I'm talking about a module "packaged" (h2xs -AX -n Foo::Bar) and then tested > (perl Makefile.PL; make; make test), when as custom configuration is like > that: > > # file t/conf/extra.conf.in > PerlModule Foo::Bar > #PerlLoadModule Foo::Bar # if uncommented catch an error when "make test" > <Location /foo> > MyFoo 30 > SetHandler modperl > PerlRequestHandler Foo::Bar > </Location> > > Obviously the variable MyFoo is corrected "handled" in Foo/Bar.pm (see > mod_perl 2.0 User's guide ch.6 for > more details) but seems to be not work under a "packaged" module. > So I can't test... only testing "by hand" (orribly long time operation..). >
I don't really understand what you mean by all this. are you saying you want to test whether MyFoo is "30" via "make test"? that's fairly simple to do. just use the "test from within a handler" approach when planning your tests - see t/response/TestDirective/perlloadmodule.pm for an example that is custom directive specific. if you're talking about testing something else, if you could take a moment to re-explain your issue I'm sure we can give you what you need. --Geoff -- Reporting bugs: http://perl.apache.org/bugs/ Mail list info: http://perl.apache.org/maillist/modperl.html