Commit | Line | Data |
2530b651 |
1 | #!/usr/bin/perl -w |
2 | |
3 | BEGIN { |
4 | if( $ENV{PERL_CORE} ) { |
5 | chdir 't' if -d 't'; |
6 | @INC = ('../lib', 'lib'); |
7 | } |
8 | else { |
9 | unshift @INC, 't/lib'; |
10 | } |
11 | } |
12 | |
13 | use strict; |
14 | use Test::More tests => 4; |
15 | |
16 | use_ok('ExtUtils::MakeMaker::bytes'); |
17 | |
18 | SKIP: { |
19 | skip "bytes.pm appeared in 5.6", 3 if $] < 5.006; |
20 | |
21 | my $chr = chr(400); |
22 | is( length $chr, 1 ); |
23 | |
24 | { |
25 | use ExtUtils::MakeMaker::bytes; |
26 | is( length $chr, 2, 'byte.pm in effect' ); |
27 | } |
28 | |
29 | is( length $chr, 1, ' score is lexical' ); |
30 | } |