public function DiffOperationTest::testGetResultWithMetadata in Zircon Profile 8.0
Same name and namespace in other branches
- 8 vendor/symfony/translation/Tests/Catalogue/DiffOperationTest.php \Symfony\Component\Translation\Tests\Catalogue\DiffOperationTest::testGetResultWithMetadata()
File
- vendor/
symfony/ translation/ Tests/ Catalogue/ DiffOperationTest.php, line 56
Class
Namespace
Symfony\Component\Translation\Tests\CatalogueCode
public function testGetResultWithMetadata() {
$leftCatalogue = new MessageCatalogue('en', array(
'messages' => array(
'a' => 'old_a',
'b' => 'old_b',
),
));
$leftCatalogue
->setMetadata('a', 'foo', 'messages');
$leftCatalogue
->setMetadata('b', 'bar', 'messages');
$rightCatalogue = new MessageCatalogue('en', array(
'messages' => array(
'b' => 'new_b',
'c' => 'new_c',
),
));
$rightCatalogue
->setMetadata('b', 'baz', 'messages');
$rightCatalogue
->setMetadata('c', 'qux', 'messages');
$diffCatalogue = new MessageCatalogue('en', array(
'messages' => array(
'b' => 'old_b',
'c' => 'new_c',
),
));
$diffCatalogue
->setMetadata('b', 'bar', 'messages');
$diffCatalogue
->setMetadata('c', 'qux', 'messages');
$this
->assertEquals($diffCatalogue, $this
->createOperation($leftCatalogue, $rightCatalogue)
->getResult());
}