[Rt-commit] r18089 - in rt/3.999/branches/merge_to_3.8.2: t/i18n
sunnavy at bestpractical.com
sunnavy at bestpractical.com
Thu Jan 29 23:24:42 EST 2009
Author: sunnavy
Date: Thu Jan 29 23:24:42 2009
New Revision: 18089
Added:
rt/3.999/branches/merge_to_3.8.2/t/i18n/
rt/3.999/branches/merge_to_3.8.2/t/i18n/default.t
Modified:
rt/3.999/branches/merge_to_3.8.2/ (props changed)
Log:
r19348 at sunnavys-mb: sunnavy | 2009-01-30 12:13:24 +0800
added t/i18n/default.t
Added: rt/3.999/branches/merge_to_3.8.2/t/i18n/default.t
==============================================================================
--- (empty file)
+++ rt/3.999/branches/merge_to_3.8.2/t/i18n/default.t Thu Jan 29 23:24:42 2009
@@ -0,0 +1,20 @@
+#!/usr/bin/perl -w
+use strict;
+use warnings;
+
+use Test::More tests => 8;
+use RT::Test;
+
+my ($baseurl, $m) = RT::Test->started_ok;
+$m->get_ok('/');
+$m->title_is('Login');
+
+$m->get_ok('/', { 'Accept-Language' => 'x-klingon' });
+$m->title_is('Login', 'unavailable language fallback to en');
+
+$m->add_header('Accept-Language' => 'zh-tw,zh;q=0.8,en-gb;q=0.5,en;q=0.3');
+$m->get_ok('/');
+use utf8;
+Encode::_utf8_on($m->{content});
+$m->title_is('登入', 'Page title properly translated to chinese');
+$m->content_contains('密碼','Password properly translated');
More information about the Rt-commit
mailing list