File: rt83267-begin.t

package info (click to toggle)
liblog-contextual-perl 0.007000-1
  • links: PTS, VCS
  • area: main
  • in suites: stretch
  • size: 320 kB
  • ctags: 75
  • sloc: perl: 615; makefile: 2
file content (23 lines) | stat: -rw-r--r-- 485 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
use Test::More qw(no_plan);

BEGIN {
   eval {
      package NotMain;

      use strict;
      use warnings;
      use Test::More;
      use Log::Contextual::SimpleLogger;

      use Log::Contextual qw(:log),
        -default_logger =>
        Log::Contextual::SimpleLogger->new({levels => [qw( )]});

      eval {
         log_info { "Yep" }
      };
      is($@, '', 'Invoked log function in package other than main');
   };

   is($@, '', 'non-main package subtest did not die');
}