Stories
Slash Boxes
Comments
NOTE: use Perl; is on undef hiatus. You can read content, but you can't post it. More info will be forthcoming forthcomingly.

All the Perl that's Practical to Extract and Report

use Perl Log In

Log In

[ Create a new account ]

nkuitse (193)

nkuitse
  (email not shown publicly)
http://www.nkuitse.com/

Journal of nkuitse (193)

Wednesday February 12, 2003
01:10 PM

Getting test religion

[ #10547 ]

Test::Inline is wonderful.

Test::More is terrific.

It's only in the past month or so that I've begun writing lots of small tests. It's only in the past month or so that I've begun writing any test code to speak of. My eyes are wide open now to new vistas.

I'm a very happy camper.

I'm tickled pink.

I'm pleased as Punch.

But in the last few days, I've found myself coding so fast that I haven't paused to write tests. Well, maybe two or three short ones. And a longer one. I guess that's not so bad: a few is better than none at all...

I wonder: am I coding fast because my newfound test religion makes working code easier to produce? No, I don't think so.

But suppose I hit that familiar wall and the code engine dries up. What then? Well, I go back to writing tests; that may just be my ticket back to Happy Hack Mode Land.

The Fine Print: The following comments are owned by whoever posted them. We are not responsible for them in any way.
 Full
 Abbreviated
 Hidden
More | Login | Reply
Loading... please wait.
  • If you want a real rush, get into test-driven development. Write a test, watch it fail, then write the code to make it pass. It's a weird but enjoyable experience to realize "That's all the code I needed to write!"

    • Actually, that's what I'm aiming for. That, or something very like it. I just need to set things up so I can cycle from design to test to code to design to test to code more easily (i.e., all from within my editor and my browser rather than switching and shifting gears ad nauseam).

      The individual tests in the modules I've been working on tend to be pretty long, though. Maybe Test::Inline can be convinced to help with that (e.g., let me specify a 'preamble' of setup code that all tests can use). Some