blob: 23fa2ac551f4aea0c45aab95f888e60ed8ef52a1 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
|
#!/usr/bin/perl -Tw
use strict;
use Test::More tests => 3;
use Locale::Maketext;
# declare a class...
{
package Woozle;
our @ISA = ('Locale::Maketext');
our %Lexicon = (
_AUTO => 1
);
keys %Lexicon; # dodges the 'used only once' warning
}
my $lh = Woozle->new();
isa_ok($lh, 'Woozle');
$@ = 'foo';
is($lh->maketext('Eval error: [_1]', $@), 'Eval error: foo', "Make sure \$@ is localized when passed to maketext");
is($@, 'foo', "\$@ wasn't modified during call");
|