/** * Constructor. * * @param Horde_Kolab_Server_Connection $connection The LDAP connection. * @param string $base_dn The LDAP server base DN. * @param string $filter A global filter to add * to all queries. */ public function __construct(Horde_Kolab_Server_Connection_Interface $connection, $base_dn) { $this->_conn = $connection; $this->_base_dn = $base_dn; try { Horde_Ldap::checkLDAPExtension(); } catch (Horde_Ldap_Exception $e) { throw new Horde_Kolab_Server_Exception($e->getMessage(), Horde_Kolab_Server_Exception::MISSING_LDAP_EXTENSION, $e); } }
public function setUp() { // Check extension. try { Horde_Ldap::checkLDAPExtension(); } catch (Horde_Ldap_Exception $e) { $this->markTestSkipped($e->getMessage()); } $config = $this->getConfig('LDAP_TEST_CONFIG'); if (!$config) { $this->markTestSkipped('No configuration for LDAP tests.'); } self::$ldapcfg = $config; }