sbekman 01/06/17 10:21:15 Modified: pod modperl_dev.pod Log: extending the server testing notes Revision Changes Path 1.26 +58 -3 modperl-2.0/pod/modperl_dev.pod Index: modperl_dev.pod =================================================================== RCS file: /home/cvs/modperl-2.0/pod/modperl_dev.pod,v retrieving revision 1.25 retrieving revision 1.26 diff -u -r1.25 -r1.26 --- modperl_dev.pod 2001/05/12 05:25:16 1.25 +++ modperl_dev.pod 2001/06/17 17:21:15 1.26 @@ -184,20 +184,75 @@ You can also use I<util/bugreport.pl>. -=head1 'make test' Debug +If you get segmentation faults see the I<'make test' Debug> section. +=head1 'make test' Features + +=head2 What Test Options are Available + +Run: + + % ./t/TEST -help + +to get the list of options you can use during testing + +=head2 'make test' Debug + mod_perl-2.0 provides built in 'make test' debug facility. So in case you get a core dump during make test, or just for fun, run in one shell: - % t/TEST -debug + % ./t/TEST -debug in another shell: - % t/TEST -run + % ./t/TEST -run then the I<-debug> shell will have a (gdb) prompt, type 'where' for stacktrace. +=head2 Running Individual Tests + +Run a single test: + + % ./t/TEST protocol/echo.t + +The server will be stopped if it was already running and a new one +will be started before running the I<t/protocol/echo.t> test. At the +end of the test the server will be shut down. + +You can run groups of tests at once. + + % ./t/TEST modules protocol/echo.t + +will run all the tests in I<t/modules/> directory, followed by +I<t/protocol/echo.t> test. + +=head2 Repeating the Tests + +By default when you run the test without I<-run-tests> option, the +server will be started before the testing and stopped at the end. If +during a debugging process you need to re-run tests without a need to +restart the server, you can start the server once: + + % ./t/TEST modules -start-httpd + +and then run the test(s) with I<-run-tests> option many times: + + % ./t/TEST -run-tests protocol/echo + +without waiting for the server to restart. + +When you are done with tests shutdown the server: + + % ./t/TEST modules -stop-httpd + +=head2 Verbose Testing + +By default print() statements in the test script are filtered out by +C<Test::Harness>. if you want the test to print what it does (if you +decide to debug some test) use C<-verbose> option: + + % t/TEST -verbose protocol/echo.t =head1 mod_perl configuration directives