Kit for Chapter 14

Quality Assurance Monitoring

The test harness script ( relies on these CPAN modules:


The generic database driver


A driver for a specific datasource (e.g., DBD::ODBC )


For web-client capability

By default, test-harness is set up to exercise the authorization script (auth.asp) from Chapter 12. Its configuration is governed by a hashtable that looks like this:

%sequence =  
  '000' => 
    'Description'  =>  'No-header request fails access to docbase record', 
    'Request'      =>  'http://localhost/cgi/auth.asp?doc=1998-10-19-000001', 
    'HeaderNames'  =>  [], 
    'HeaderValues' =>  [], 
  '003' => 
    'Description'  =>  'Valid basic-auth user fails feed registration', 
    'Request'      =>  'http://localhost/cgi/auth.asp?doc=1998-10-19-000001', 
    'HeaderNames'  =>  ['Authorization'], 
    'HeaderValues' =>  ['Basic QWxhZGRpbjpvcGVuIHNlc2FtZQ=='], 
    'Constructor'  => 'unRegisterAladdinForNetscape', 
    'Destructor'   => 'reRegisterAladdinForNetscape', 

To configure test-harness for some other web application, rewrite this hashtable. You might prefer to swap in your own stuff, since the authorizing docbase viewer used here is a bit complex to set up. Specify one or more requests, optionally with HTTP headers and optionally with the names of Constructor and Destructor routines that prepare the environment for a test and clean up after it.

To gather baseline data, run test-harness once in baseline mode, like this:

perl test-harness baseline

Then run it in test mode, ...

Get Practical Internet Groupware now with the O’Reilly learning platform.

O’Reilly members experience live online training, plus books, videos, and digital content from nearly 200 publishers.