public function testGetsDefaultAttributes()
 {
     $configFile = new FakeConfigFile();
     $configFile->SetKey(ActiveDirectoryConfig::ATTRIBUTE_MAPPING, '');
     $this->fakeConfig->SetFile(ActiveDirectoryConfig::CONFIG_ID, $configFile);
     $options = new ActiveDirectoryOptions();
     $expectedAttributes = array('sn', 'givenname', 'mail', 'telephonenumber', 'physicaldeliveryofficename', 'title');
     $this->assertEquals($expectedAttributes, $options->Attributes());
 }
Example #2
0
 public function testGetsDefaultUserIdAttribute()
 {
     $configFile = new FakeConfigFile();
     $configFile->SetKey(LdapConfig::USER_ID_ATTRIBUTE, '');
     $this->fakeConfig->SetFile(LdapConfig::CONFIG_ID, $configFile);
     $options = new LdapOptions();
     $this->assertEquals('uid', $options->GetUserIdAttribute());
 }