Пример #1
0
 public function testGetMultipleComponentsAsArray()
 {
     $config = array('YadifBaz' => array('class' => 'YadifBaz'), 'YadifFoo' => array('class' => 'YadifFoo', 'arguments' => array(':foo', 'YadifBaz'), 'params' => array(':foo' => 'aloah!')));
     $yadif = new Yadif_Container($config);
     $components = $yadif->getComponents(array('foo' => 'YadifFoo', 'baz' => 'YadifBaz'));
     $this->assertEquals('aloah!', $components['foo']->a);
     $this->assertEquals($components['foo']->b, $components['baz']);
 }