Exemplo n.º 1
0
 /**
  * @test
  */
 public function theStorageCanBeRetrievedAsArray()
 {
     $objectStorage = new Tx_Extbase_Persistence_ObjectStorage();
     $object1 = new StdClass();
     $object2 = new StdClass();
     $objectStorage->attach($object1, 'foo');
     $objectStorage->attach($object2, 'bar');
     $this->assertEquals($objectStorage->toArray(), array($object1, $object2));
 }
 /**
  * @see Tx_Extbase_Persistence_ObjectStorage::toArray
  */
 public function toArray()
 {
     $this->initialize();
     return parent::toArray();
 }