Return-Path: Delivered-To: apmail-httpd-test-dev-archive@httpd.apache.org Received: (qmail 93648 invoked by uid 500); 17 Jun 2003 16:03:18 -0000 Mailing-List: contact test-dev-help@httpd.apache.org; run by ezmlm Precedence: bulk Reply-To: test-dev@httpd.apache.org list-help: list-unsubscribe: list-post: Delivered-To: mailing list test-dev@httpd.apache.org Received: (qmail 93517 invoked from network); 17 Jun 2003 16:03:17 -0000 Message-ID: <3EEF3BC5.7010303@modperlcookbook.org> Date: Tue, 17 Jun 2003 12:03:17 -0400 From: Geoffrey Young User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.0.1) Gecko/20020823 Netscape/7.0 X-Accept-Language: en-us, en MIME-Version: 1.0 To: test-dev@httpd.apache.org CC: Ken Williams Subject: Re: Perl Testing References: <8C8EA1A6-A0DB-11D7-A7F6-0003931A964A@kineticode.com> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N > 1. The documentation is pretty lacking. Granted, it was bad in > Apache::test, too, but I sure would like to see some decent pod in each > of the important Apache::Test* modules. agreed. resources you may find useful (if you haven't seen them already): http://www.perl.com/pub/a/2003/05/22/testing.html http://perl.apache.org/docs/general/testing/testing.html there is also some good information in the README http://search.cpan.org/src/STAS/Apache-Test-1.01/README > 3. Those of us porting from Apache::test typically have a special > configuration file (now nicely able to be t/lib/extra.conf.in -- > thanks!) and loads up the libraries we want to test. However, Apache > isn't being started during `make test` with C. Now, since > tests run from t, even it it did C, it wouldn't work. So I had > to add this code to my extra.conf.in: > > > use File::Spec::Functions qw(catdir); > use lib catdir '@ServerRoot@', '..', 'blib'; > use lib catdir '@ServerRoot@', '..', 'lib'; > for the most part, Apache-Test does the right thing. the only exception I've noticed is for modules that use XS or otherwise need to be preloaded. the solution for this is to to use t/conf/extra.last.conf.in in place of t/conf/extra.conf.in. this allows Apache-Test to set the proper blib (via PerlRequre) before including modules from your configuration. even if you don't use XS, this may solve your problem. you can also extend libraries, etc, via t/conf/modperl_extra.pl HTH --Geoff