summaryrefslogtreecommitdiff
path: root/cpan/encoding-warnings/t/3-normal.t
blob: f0e6446a56b25a8c5696817d59a50ef1b5d0070a (plain)
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;
BEGIN { plan tests => 2 }

use strict;
use encoding::warnings 'FATAL';
ok(encoding::warnings->VERSION);

if ($] < 5.008) {
    ok(1);
    exit;
}

my ($a, $b, $c, $ok);
$ok = 1;

$SIG{__DIE__} = sub { $ok = 0 };
$SIG{__WARN__} = sub { $ok = 0 };

$a = chr(20000);
$b = chr(20000);
$c = $a . $b;

ok($ok);