You are here

public function TranslatorTest::testFlattenedTrans in Plug 7

@dataProvider getFlattenedTransTests

File

lib/Symfony/translation/Tests/TranslatorTest.php, line 317

Class

TranslatorTest

Namespace

Symfony\Component\Translation\Tests

Code

public function testFlattenedTrans($expected, $messages, $id) {
  $translator = new Translator('en');
  $translator
    ->addLoader('array', new ArrayLoader());
  $translator
    ->addResource('array', $messages, 'fr', '');
  $this
    ->assertEquals($expected, $translator
    ->trans($id, array(), '', 'fr'));
}