5 print "1..0 # Skipped: your perl don't know unicode\n";
13 use Digest::MD5 qw(md5_hex);
16 $str = "foo\xFF\x{100}";
20 print "not ok 1\n"; # should not run
22 print "not " unless $@ && $@ =~ /^(Big byte|Wide character)/;
25 my $exp = ord "A" == 193 ? # EBCDIC
26 "c307ec81deba65e9a222ca81cd8f6ccd" :
27 "503debffe559537231ed24f25651ec20"; # Latin 1
29 chop($str); # only bytes left
30 print "not " unless md5_hex($str) eq $exp;
34 print "not " unless md5_hex("foo\xFF") eq $exp;