Fixes for testing
This commit is contained in:
26
tests/Feature/GetBaseDNTest.php
Normal file
26
tests/Feature/GetBaseDNTest.php
Normal file
@@ -0,0 +1,26 @@
|
||||
<?php
|
||||
|
||||
namespace Tests\Feature;
|
||||
|
||||
use Tests\TestCase;
|
||||
|
||||
use App\Classes\LDAP\Server;
|
||||
|
||||
class GetBaseDNTest extends TestCase
|
||||
{
|
||||
/**
|
||||
* Test that we can get the Base DN of an LDAP server
|
||||
*
|
||||
* @return void
|
||||
* @throws \LdapRecord\Query\ObjectNotFoundException
|
||||
* @covers \App\Classes\LDAP\Server::baseDNs()
|
||||
*/
|
||||
public function testBaseDnExists()
|
||||
{
|
||||
$o = Server::baseDNs();
|
||||
|
||||
$this->assertIsObject($o);
|
||||
$this->assertCount(6,$o->toArray());
|
||||
$this->assertEquals('dc=Test',$o->first()->getDn());
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user