X-Git-Url: http://git.ieval.ro/?a=blobdiff_plain;f=t%2FApp-Lastmsg.t;h=b8ad563ee4567a01f8ecae202df600e7fe30468a;hb=HEAD;hp=a9845098fc2e2632775d2d4e4251917ba8a20034;hpb=8d77279934f4257a0ea5c7f3ac29f99f00f0d5f1;p=app-lastmsg.git diff --git a/t/App-Lastmsg.t b/t/App-Lastmsg.t index a984509..b8ad563 100644 --- a/t/App-Lastmsg.t +++ b/t/App-Lastmsg.t @@ -2,7 +2,7 @@ use strict; use warnings; -use Test::More tests => 2; +use Test::More tests => 3; BEGIN { use_ok('App::Lastmsg') }; { @@ -22,3 +22,18 @@ user2 user2@example.org 1483182600 user1 user1@example.com 1483105440 user3 NOT FOUND EOF + +$ENV{LASTMSG_DEBUG} = 1; +my $err = ''; +close STDERR; +open STDERR, '>', \$err or die "$!"; +App::Lastmsg::run; + +is $err, <<'EOF', 'debug output is correct'; +Scanning inbox (inbox) +Processing from User 1 (Comment) +Processing from user1@example.com +Processing from user2@example.com +Scanning sent (sent) +Processing <33r32r32igf432g@localhost.localdomain> sent to Random User (Very random), User 2 +EOF