Merge pull request #5962 from marc1706/ticket/16462

[ticket/16462] Skip tests that require the LDAP extension
This commit is contained in:
Marc Alexander 2020-05-03 11:01:36 +02:00
commit 6fc6e7ced2
No known key found for this signature in database
GPG key ID: 50E0D2423696F995

View file

@ -53,11 +53,21 @@ class phpbb_auth_provider_ldap_test extends phpbb_database_test_case
*/ */
public function test_init() public function test_init()
{ {
if (!extension_loaded('ldap'))
{
$this->markTestSkipped('LDAP extension not available.');
}
$this->assertFalse($this->provider->init()); $this->assertFalse($this->provider->init());
} }
public function test_login() public function test_login()
{ {
if (!extension_loaded('ldap'))
{
$this->markTestSkipped('LDAP extension not available.');
}
$username = 'admin'; $username = 'admin';
$password = 'adminadmin'; $password = 'adminadmin';