public function MessageCatalogueTest::testGetAddResource in Plug 7
File
- lib/
Symfony/ translation/ Tests/ MessageCatalogueTest.php, line 148
Class
Namespace
Symfony\Component\Translation\TestsCode
public function testGetAddResource() {
$catalogue = new MessageCatalogue('en');
$r = $this
->getMock('Symfony\\Component\\Config\\Resource\\ResourceInterface');
$r
->expects($this
->any())
->method('__toString')
->will($this
->returnValue('r'));
$catalogue
->addResource($r);
$catalogue
->addResource($r);
$r1 = $this
->getMock('Symfony\\Component\\Config\\Resource\\ResourceInterface');
$r1
->expects($this
->any())
->method('__toString')
->will($this
->returnValue('r1'));
$catalogue
->addResource($r1);
$this
->assertEquals(array(
$r,
$r1,
), $catalogue
->getResources());
}