I am trying to put together a comprehensive regression suite for CGI based
mod_perl web applications using LWP.  It involves sequences of CGI calls
with expected results after each consecutive request.  But I noticed
something about LWP: it caches requests, almost like it expects *only*
static content.  So if you loop over a given sequence of HTTP requests, only
the first one actually gets sent to the server.

  eg:

foreach (1..5) {
   $ua->request(GET ('http://localhost/uri1'));
   $ua->request(GET ('http://localhost/uri2'));
   $ua->request(GET ('http://localhost/uri3'));
}

# this code will only send 3 requests to the webserver, NOT 15

Has anyone done similar work making a regression test using LWP ?  Is there
an easy way to turn off this caching behavior?

-Adi

Reply via email to