http://qs321.pair.com?node_id=830995

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

Hello,

When I run this test which will intentionally fail,
#!/usr/bin/perl use warnings; use strict; use Test::More tests => 1; my $test_ls = `lxs`; like( $test_ls, qr/incorrect/, 'lxs command is missing.' );
It gives me this output.
1..1 Can't exec "lxs": No such file or directory at ./1.t line 7. Use of uninitialized value in pattern match (m//) at ./1.t line 9. not ok 1 - lxs command is missing. # Failed test 'lxs command is missing.' # at ./1.t line 9. # undef # doesn't match '(?-xism:incorrect)' # Looks like you failed 1 test of 1.
Is there a way to make it less verbose? I wanted something like 'Failed test 'lxs command is missing.'.

And is there a way to remove this 'Use of uninitialized value in pattern match'?