Add 5.11.3 to perlhist.
[p5sagit/p5-mst-13.2.git] / dist / Locale-Maketext / t / 90_utf8.t
1 #!/usr/bin/perl -Tw
2
3 use strict;
4 use Test::More tests => 3;
5
6 BEGIN {
7     use_ok( 'Locale::Maketext', 1.01 );
8 }
9
10 use utf8;
11
12 # declare some classes...
13 {
14     package Woozle;
15     our @ISA = ('Locale::Maketext');
16     sub dubbil   { return $_[1] * 2 . chr(2000) }
17     sub numerate { return $_[2] . 'en' }
18 }
19 {
20     package Woozle::eu_mt;
21     our @ISA = ('Woozle');
22     our %Lexicon = (
23         'd2' => chr(1000) . 'hum [dubbil,_1]',
24         'd3' => chr(1000) . 'hoo [quant,_1,zaz]',
25         'd4' => chr(1000) . 'hoo [*,_1,zaz]',
26     );
27     keys %Lexicon; # dodges the 'used only once' warning
28 }
29
30 my $lh = Woozle->get_handle('eu-mt');
31 isa_ok( $lh, 'Woozle::eu_mt' );
32 is( $lh->maketext('d2', 7), chr(1000).'hum 14'.chr(2000) );
33