Test.pm to Test::More Partial Conversion

Previously Perl test-programs used the built-in Test.pm module, but it has many limitations. Test::More is much better, but its ok() method is incompatible with Test.pm. As a result, I'm providing this script to do a partial machine conversion of Test.pm-based legacy scripts to Test::More. It makes use of PPI - The Perl Parsing Interface



  • Does not translate the “use Test;” to “use Test::More” or convert the plan.

  • No option to avoid adding the Test-Count annotations.

  • Can mess up single-parameter ok() tests with low-precedence operators such as not

  • Does not handle counts of tests inside loops.

  • No correctness tests.

  • Not packaged as a CPAN distribution.

Patches for some of these would be welcome.


Test.pm-to-Test-More.pl is free and open-source software (FOSS) distributed under the MIT/Expat License, a permissive, public-domain-like, software licence.


Blog Posts