Ejemplo n.º 1
0
 /**
  * Testing the loadAllByAttributes method.
  *
  * @since 1.0
  * @dataProvider getActiveRecordProviders
  */
 public function testLoadAllByAttributes($provider)
 {
     $config = ConfigProvider::getInstance();
     $config->set('db.provider.name', $provider);
     $this->person->save();
     $people = $this->person->loadAllByAttributes(array('OID'), array($this->person->getOID()));
     $this->assertEquals(1, count($people), 'Testing the loadAllByAttribute method');
     $this->assertEquals('unitTestUser', $people[0]->getDisplayname()->getValue(), 'Testing the loadAllByAttributes method');
     $people[0]->delete();
 }