Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:
I've inherited an extremely large app written with CGI.pm and running under mod_perl. It's well-written, as it goes (or would have been regarded as well-written 15 years ago), but everything is lumped together; there's no separation of concerns at all. It's the intention to rewrite this using modern standards (probably Catalyst or Mojolicious), but in the meantime, there are no tests for this app and I need to get at least some basic ones going. A Mechanize script is going to be the only way of accomplishing this, because of the lack of separation.
Is there a test framework that will run this internally, so that I don't have to have a separate Apache installation just for testing (it would be politically impossible to set something like this up)? Similarly, what's the easiest way to mock a database for testing purposes? (The production DB is SQL Server.)
I'm used to the various Catalyst things that do this seamlessly and behind the scenes. I don't really care about how to accomplish this, I just want some simple way of getting started so I can start writing test scripts.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Testing large legacy CGI app
by Corion (Patriarch) on Jan 27, 2016 at 15:30 UTC | |
|
Re: Testing large legacy CGI app
by LanX (Saint) on Jan 27, 2016 at 19:54 UTC |