You are here

public function PoFileLoaderTest::testEscapedId in Plug 7

File

lib/Symfony/translation/Tests/Loader/PoFileLoaderTest.php, line 73

Class

PoFileLoaderTest

Namespace

Symfony\Component\Translation\Tests\Loader

Code

public function testEscapedId() {
  $loader = new PoFileLoader();
  $resource = __DIR__ . '/../fixtures/escaped-id.po';
  $catalogue = $loader
    ->load($resource, 'en', 'domain1');
  $messages = $catalogue
    ->all('domain1');
  $this
    ->assertArrayHasKey('escaped "foo"', $messages);
  $this
    ->assertEquals('escaped "bar"', $messages['escaped "foo"']);
}