Пример #1
0
 protected function createFixture($name, $data = array(), $properties = array())
 {
     $fixture = new Fixture($name, 'default');
     foreach ($data as $key => $value) {
         $fixture->add(new FixtureData($key, $value));
     }
     $fixture->setProperties(new ParameterBag($properties));
     return $fixture;
 }
Пример #2
0
 /**
  *
  * @param  array $data
  * @return FixtureCollection
  */
 public static function create(array $data)
 {
     $collection = new self();
     foreach ($data as $name => $info) {
         $collection->add(Fixture::create($name, $info));
     }
     return $collection;
 }
Пример #3
0
 /**
  *
  * @return array
  */
 public function getProperties()
 {
     return $this->fixture->getProperties();
 }