Integrate mainline
[p5sagit/p5-mst-13.2.git] / ext / Encode / t / Encode.t
index 3f5d206..28becb4 100644 (file)
@@ -1,12 +1,13 @@
 BEGIN {
     chdir 't' if -d 't';
-    @INC = '../lib';
+    push @INC, '../lib';
     require Config; import Config;
     if ($Config{'extensions'} !~ /\bEncode\b/) {
       print "1..0 # Skip: Encode was not built\n";
       exit 0;
     }
 }
+use strict;
 use Test;
 use Encode qw(from_to encode decode
              encode_utf8 decode_utf8
@@ -112,7 +113,7 @@ for my $i (256,128,129,256)
  }
 
 # Spot check a few points in/out of utf8
-for my $i (0x41,128,256,0x20AC)
+for my $i (ord('A'),128,256,0x20AC)
  {
   my $c = chr($i);
   my $o = encode_utf8($c);
@@ -135,6 +136,3 @@ $a = "\x{100}";
 chop $a;
 ok(  is_utf8($a)); # weird but true: an empty UTF-8 string
 
-
-
-