public function PoFileLoaderTest::testLoadPlurals in Plug 7
File
- lib/
Symfony/ translation/ Tests/ Loader/ PoFileLoaderTest.php, line 30
Class
Namespace
Symfony\Component\Translation\Tests\LoaderCode
public function testLoadPlurals() {
$loader = new PoFileLoader();
$resource = __DIR__ . '/../fixtures/plurals.po';
$catalogue = $loader
->load($resource, 'en', 'domain1');
$this
->assertEquals(array(
'foo' => 'bar',
'foos' => 'bar|bars',
), $catalogue
->all('domain1'));
$this
->assertEquals('en', $catalogue
->getLocale());
$this
->assertEquals(array(
new FileResource($resource),
), $catalogue
->getResources());
}