Tomte has asked for the wisdom of the Perl Monks concerning the following question:

Fellow Monks,

I find myself in the uncomforting situation of being responsible for an angry customer, because a colleague updated a webapp without checking it's functionality, as part of a complete site-update.
I'm responsible, because I commited changes that broke the app (the last step in a whole bunch of steps didn't work anymore).

I thought about using webchat to do the automation, as it seems the only viable framework for such things except for 'roling my own'.

What is your experience with this module? It seems to be unmaintained, as there's not a change in well over a year; in most cases, this didn't matter, but you never know
Is it useful/feasible to test complex webapps with this tool?
What do you use? Someone with a kick in the right direction?

regards,
tomte


Replies are listed 'Best First'.
Re: WebApplication test-automation
by adrianh (Chancellor) on Feb 18, 2003 at 09:36 UTC

    WWW::Mechanize rocks for this sort of testing task. I'd strongly consider it over webchat.

    Very nice in combination with the various Test:: libraries.

      ++ adrianh,
      seems to be a good suggestion, as there's not the hassle that's there using Inline::WebChat with multiple tests.

      regards,
      tomte


Re: WebApplication test-automation
by knowmad (Monk) on Feb 18, 2003 at 14:00 UTC
    You may want to check out HTTP::WebTest as well. It facilitates testing of the responses that come back from your web application. I use it to run weekly tests against my systems as well as during development to run a more complete series of tests to ensure operation of all functions.
Re: WebApplication test-automation
by Corion (Patriarch) on Feb 18, 2003 at 14:33 UTC

    I have an application written in CGI::Application, and CGI::Application has an offline mode that directly returns a string instead of printing it - and then I write tests against that returned string (or rather, I parse the response into headers and body, and test the headers and the body). Test::HTML::Content is still crude and not yet ported to XPath syntax, but it might help already.

    perl -MHTTP::Daemon -MHTTP::Response -MLWP::Simple -e ' ; # The $d = new HTTP::Daemon and fork and getprint $d->url and exit;#spider ($c = $d->accept())->get_request(); $c->send_response( new #in the HTTP::Response(200,$_,$_,qq(Just another Perl hacker\n))); ' # web