The London Perl and Raku Workshop takes place on 26th Oct 2024. If your company depends on Perl, please consider sponsoring and/or attending.


Acme::Test::42 - Test the answer to ultimate question


 use Acme::Test::42 qw(no_plan);
 # . . .
 ok($answer, 'Answer to the question');
 not_ok($answer / 2, 'Not an answer');


Acme::Test::42 provides a mechanism for probing if the answer is correct.


Acme::Test::42 exports two subroutines, ok and not_ok, each of them expects two arguments: the answer and optional comment.

The module is based on standard Test::Builder and follows the TAP standard but unlike Test::Simple and Test::More does not expect true or false values and checks if the given value is an answer to the ultimate question of life, the Universe, and everything.

Perl people often use this answer in their talks (see and as a boolean value returned by Perl packages (see Acme::ReturnValue), which makes Acme::Test::42 so important.


Andrew Shitov, <>


Acme::Test::42 module is a free software. You may redistribute and (or) modify it under the same terms as Perl whichever version it is.