You are here

public function XliffFileLoaderTest::testIncompleteResource in Plug 7

File

lib/Symfony/translation/Tests/Loader/XliffFileLoaderTest.php, line 53

Class

XliffFileLoaderTest

Namespace

Symfony\Component\Translation\Tests\Loader

Code

public function testIncompleteResource() {
  $loader = new XliffFileLoader();
  $catalogue = $loader
    ->load(__DIR__ . '/../fixtures/resources.xlf', 'en', 'domain1');
  $this
    ->assertEquals(array(
    'foo' => 'bar',
    'key' => '',
    'test' => 'with',
  ), $catalogue
    ->all('domain1'));
  $this
    ->assertFalse($catalogue
    ->has('extra', 'domain1'));
}