summaryrefslogtreecommitdiff
path: root/ext/I18N-LangTags/t/07_listy.t
blob: a56a798a333e60e35593fd6a88f52920ffe2faeb (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30

require 5;
 # Time-stamp: "2003-10-10 17:37:34 ADT"
use strict;
use Test;
BEGIN { plan tests => 17 };
BEGIN { ok 1 }
use I18N::LangTags::List;

print "# Perl v$], I18N::LangTags::List v$I18N::LangTags::List::VERSION\n";

ok  I18N::LangTags::List::name('fr'), 'French';
ok  I18N::LangTags::List::name('fr-fr');
ok !I18N::LangTags::List::name('El Zorcho');
ok !I18N::LangTags::List::name();


ok !I18N::LangTags::List::is_decent();
ok  I18N::LangTags::List::is_decent('fr');
ok  I18N::LangTags::List::is_decent('fr-blorch');
ok !I18N::LangTags::List::is_decent('El Zorcho');
ok !I18N::LangTags::List::is_decent('sgn');
ok  I18N::LangTags::List::is_decent('sgn-us');
ok !I18N::LangTags::List::is_decent('i');
ok  I18N::LangTags::List::is_decent('i-mingo');
ok  I18N::LangTags::List::is_decent('i-mingo-tom');
ok !I18N::LangTags::List::is_decent('cel');
ok  I18N::LangTags::List::is_decent('cel-gaulish');

ok 1; # one for the road