Beefy Boxes and Bandwidth Generously Provided by pair Networks
Do you know where your variables are?
 
PerlMonks  

Re: Skip tests if/unless $ENV{FOO} is set using Test::More

by Rex(Wrecks) (Curate)
on Apr 29, 2003 at 20:55 UTC ( [id://254094]=note: print w/replies, xml ) Need Help??


in reply to Skip tests if/unless $ENV{FOO} is set using Test::More

IMHO (and I have made software and hardware QA my business :) it looks like the problem here is that the test scope is pointed in the wrong direction.

I would hope that all of these tests are being run on as many platforms as are available BEFORE the code is ever downloaded. It seems to me that these tests should be a small, basic subset of the major test suites, and...

...Here's the kicker...

...should be testing that the module has INSTALLED properly, and the basics work as expected on that platform!

22,000 tests is not the basics, it is rather excessive for testing if the installation was successful. Having an option to run all 22,000 tests? Sure, someone might need to know the results of that for various reasons, and if they have the requirement to get that knowlege they will hopefully have the patience to get it.

I would really encourage people to ship as many of their tests as possible with the modules and packages, and even have instructions on how to run them, the debugging benifits are obvious. But please not as an install test, an install test should test exactly that, was the installation successful?

Scope is a very important thing to keep in mind when applying testing to anything. Just because you can and do execute these tests, does not mean they are appropriate for every place that testing is required.

How would you feel if every test ever written for your OS was executed every time the computer booted? or even every time you did an install?

"Nothing is sure but death and taxes" I say combine the two and its death to all taxes!

Replies are listed 'Best First'.
Re^2: Skip tests if/unless $ENV{FOO} is set using Test::More
by adrianh (Chancellor) on Apr 29, 2003 at 21:36 UTC

    I don't think this approach will work well for Perl/CPAN. It's not practical for the average CPAN contributer to test on all perl platforms, perl versions and possible prequisite module versions before distribution.

    Stick a module on CPAN and you get a distributed testing farm for free, with CPAN Testers thrown in as a bonus.

    It's one of the hidden benefits of CPAN and one of the reasons Perl modules end up being so robust (IMHO :-)

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others admiring the Monastery: (4)
As of 2024-03-29 00:31 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found