Beefy Boxes and Bandwidth Generously Provided by pair Networks
Come for the quick hacks, stay for the epiphanies.
 
PerlMonks  

Re^2: how to begin with testing?

by DrHyde (Prior)
on Mar 23, 2009 at 13:53 UTC ( [id://752596]=note: print w/replies, xml ) Need Help??


in reply to Re: how to begin with testing?
in thread how to begin with testing?

Agreed, with one exception - that being if you want to re-factor the code or make major architectural changes. Then you need tests that exercise the application thoroughly so that you can be sure that your changes don't break anything.

As for how to write an application in such a way as to be easily tested - instead of a huge monolith, break it into chunks so that each little bit of functionality can be easily tested. For example, if your application has a config file, then instead of scattering configgish stuff throughout the app, abstract it out into a module that provides functions for reading and parsing the file, and for getting at the information, which can be tested entirely seperate from the main body of the app.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://752596]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others drinking their drinks and smoking their pipes about the Monastery: (4)
As of 2024-03-19 07:40 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found