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

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.
  • ...and now it makes plans almost irrelevant.
    This is one of those bits of yak shaving that Perl programmers seem to think is necessary. It always baffled me, even when I was a full fledged Perl guy, that I had to specify my plan up front. Just run the tests I give you!
    • So how do you know you didn’t run fewer tests than you meant to?

      Yes, OK, that was easy. Now tell me how you know you didn’t run more tests than you meant to.

      • Just how are you supposed to know how many tests you planned?

        Anyway... how about an end marker, "yes I'm done", a sub you call at the end of your test file. All it has to do is set a flag in the test module.

        done;
        If the tests are interrupted, it won't get called, and then you'll know, as the test module will check the status of that flag in its END block.

        Something like that.

        • Just how are you supposed to know how many tests you planned?

          What am I supposed to say to that?

          If the tests are interrupted, it won’t get called, and then you’ll know

          Right, that was the easy part I talked about.

          • What am I supposed to say to that?

            What I was aiming as was that with the old school test modules, you have to state how many tests you plan on executing. But how can you know? Counting them manually? Running the tests, toping they all get executed, and check how many were done in the error message?

            That is not ideal. I'd even prefer a dry run, using ok/nok to just count the tests without actually doing them, to this. Maybe do the real test in a live run immediately after that.