Beefy Boxes and Bandwidth Generously Provided by pair Networks
Your skill will accomplish
what the force of many cannot
 
PerlMonks  

Answer: How to test a module which needs a local HTTP server?

( #427834=categorized answer: print w/ replies, xml ) Need Help??

Q&A > testing > How to test a module which needs a local HTTP server? contributed by jplindstrom

Depending on what you really need to test, it may work to... not use a web server. Check out WWW::Mechanize::Cached.

First you run your tests live on your machine while having the caching function save the pages to files (or some other caching mechanism). Then you can just re-run the test again, essentially in off-line mode since the results will come from disk.

I actually started doing this today when the thing to test wasn't "get web page", but to combine that with some processing.

/J

Comment on Answer: How to test a module which needs a local HTTP server?
Log In?
Username:
Password:

What's my password?
Create A New User
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others about the Monastery: (11)
As of 2014-08-22 10:13 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The best computer themed movie is:











    Results (153 votes), past polls