File: 04alias.t

package info (click to toggle)
libmime-charset-perl 1.006.2-2
  • links: PTS, VCS
  • area: main
  • in suites: lenny
  • size: 200 kB
  • ctags: 40
  • sloc: perl: 627; makefile: 41
file content (22 lines) | stat: -rw-r--r-- 536 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
use strict;
use Test;

BEGIN { plan tests => 26 }

my @names = qw(
	    US-ASCII
	    ISO-8859-1 ISO-8859-2 ISO-8859-3 ISO-8859-4 ISO-8859-5
	    ISO-8859-6 ISO-8859-7 ISO-8859-8 ISO-8859-9 ISO-8859-10
	    SHIFT_JIS EUC-JP ISO-2022-KR EUC-KR ISO-2022-JP ISO-2022-JP-2
	    ISO-8859-6-I ISO-8859-6-E ISO-8859-8-E ISO-8859-8-I
	    GB2312 BIG5 KOI8-R
	    UTF-8
	    HZ-GB-2312
	   );

use MIME::Charset qw(:info);

foreach my $name (@names) {
    my $aliased = MIME::Charset->new($name)->as_string;
    ok($aliased, $name, $aliased);
}