Beispiel #1
0
 public function method1()
 {
     $barDomain = 'bardomain';
     T::trans('Some simple token');
     $message = 'hello ';
     $message .= 'world';
     T::trans('We got something for ya, %s!', array('name' => 'Vassily', 'xxx' => $fn()), 'foodomain');
     T::trans('Another token', null, $barDomain);
     T::trans($message);
     T::trans('Broken translation', null, rand(100));
     T::transChoice('This is "transChoice token"', null, null, 'tcdomain');
 }
Beispiel #2
0
 public function testTransChoice()
 {
     $expectedOutput = array('foo id', 'foo number', array('params'), 'foo domain', 'foo locale');
     $this->assertSame($expectedOutput, T::transChoice('foo id', 'foo number', array('params'), 'foo domain', 'foo locale'));
 }