Beefy Boxes and Bandwidth Generously Provided by pair Networks
There's more than one way to do things
 
PerlMonks  

Automating TDD

by tmaly (Monk)
on Dec 03, 2010 at 05:09 UTC ( [id://875077]=perlquestion: print w/replies, xml ) Need Help??

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

Monks,
I am looking for advice or your tricks on how to better automate test driven development?

Right now, I have some simple perl scripts I call from vim short cuts to create the bare bones test for a OO module.


Best Regards,
Ty

UPDATE:
Thank you for all your responses. I came across this module Test::StubGenerator that I think might do what I was looking for, but I can alway subclass it to make changes

Best Regards
Ty

Replies are listed 'Best First'.
Re: Automating TDD
by GrandFather (Saint) on Dec 03, 2010 at 05:51 UTC

    So the next step is to write a script or scripts to run your tests and perform code coverage. To the extent that I've used TDD I found that code coverage analysis gave the most bang for the buck in terms of where to focus tests and how well the tests were performing.

    During the development phase I achieved and maintained 100% coverage, but that slipped when the project switched to a maintenance phase and by now I suspect the coverage statistics may be rather frightening.

    True laziness is hard work
Re: Automating TDD
by perl_lover (Chaplain) on Dec 03, 2010 at 07:58 UTC
    Get your project into Hudson continuous integration (http://hudson-ci.org/). This will make sure you have good coverage and unit tests are updated even when the project goes to maintenance mode.
Re: Automating TDD
by pemungkah (Priest) on Dec 04, 2010 at 00:28 UTC
Re: Automating TDD
by BrimBorium (Friar) on Dec 05, 2010 at 18:21 UTC

    I use Test::Harness and Test::More to write automated module tests. That's extremely helpful also for regression testing. If you change something in your code you just run the tests again and get a pass/fail statistics.

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others admiring the Monastery: (3)
As of 2024-04-26 07:08 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found