http://www.perlmonks.org?node_id=942873

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

Greeting fellow scholars in the noble art of perl.

This is mostly a hypothetical question, rather than a problem I am facing now: When you install a perl module from CPAN the normal install process involves running a series of unit tests to make sure that the module is correct, and that it works correctly in your environment. If your environment lacks features needed for the module to run, then the tests should fail and CPAN will refuse to install it without force.

The problem is that those tests are only valid on the day they are run. People change their environment all the time. They upgrade their Linux distros, they add and remove hardware, they change their system software and libraries, they even upgrade perl, and then point it at libraries installed under an older version. CPAN module tests that ran OK in the past might not run any more.

Given this, is there a way to re-run the tests for modules that are already installed, to check against the possibility that some change since the install has broken them?

It would be nice if there was some configuration variable you could give CPAN to tell it to retain and install all the .t files that came with a module, and a command you could run to tell it to run all those tests. Is there such an option?