Subject: | assert() throws warnings when $@ is not set. |
To reproduce simply run test.pl with warnings turned on.
$ perl -Mblib -w test.pl
Use of uninitialized value in concatenation (.) or string at /usr/local/src/CPAN/Test-Extreme-0.12/blib/lib/Test/Extreme.pm line 34.
Use of uninitialized value in concatenation (.) or string at /usr/local/src/CPAN/Test-Extreme-0.12/blib/lib/Test/Extreme.pm line 34.
Use of uninitialized value in concatenation (.) or string at /usr/local/src/CPAN/Test-Extreme-0.12/blib/lib/Test/Extreme.pm line 34.
Use of uninitialized value in concatenation (.) or string at /usr/local/src/CPAN/Test-Extreme-0.12/blib/lib/Test/Extreme.pm line 34.
Use of uninitialized value in concatenation (.) or string at /usr/local/src/CPAN/Test-Extreme-0.12/blib/lib/Test/Extreme.pm line 34.
Use of uninitialized value in concatenation (.) or string at /usr/local/src/CPAN/Test-Extreme-0.12/blib/lib/Test/Extreme.pm line 34.
Use of uninitialized value in concatenation (.) or string at /usr/local/src/CPAN/Test-Extreme-0.12/blib/lib/Test/Extreme.pm line 34.
Use of uninitialized value in concatenation (.) or string at /usr/local/src/CPAN/Test-Extreme-0.12/blib/lib/Test/Extreme.pm line 34.
Use of uninitialized value in concatenation (.) or string at /usr/local/src/CPAN/Test-Extreme-0.12/blib/lib/Test/Extreme.pm line 34.
1..19
ok 1
...etc...
assert() will try to report $@ when it fails but if $@ is not set you get the unint warnings as above. This seems to be unique to Test::Extreme and probably has to do with its trapping failing tests in eval blocks. I cannot easily reproduce it with a small code snippet but I didn't try very hard.