implemented RequestedUserRightFacadeService

This commit is contained in:
Kevin Frantz 2019-01-16 22:15:00 +01:00
parent 1651ff95f7
commit effb1fc6da
4 changed files with 54 additions and 1 deletions

View File

@ -9,7 +9,7 @@ use App\Exception\SetNotPossibleException;
/**
* @author kevinfrantz
*/
final class RequestedUserRightFacade implements RequestedUserRightFacadeInterface
class RequestedUserRightFacade implements RequestedUserRightFacadeInterface
{
/**
* @var UserSourceDirectorInterface

View File

@ -0,0 +1,20 @@
<?php
namespace App\Domain\RequestManagement;
use App\Domain\UserManagement\UserSourceDirectorServiceInterface;
/**
* @author kevinfrantz
*/
final class RequestedUserRightFacadeService extends RequestedUserRightFacade implements RequestedUserRightFacadeServiceInterface
{
/**
* @param UserSourceDirectorServiceInterface $userSourceDirectorService
* @param RequestedRightServiceInterface $requestedRightService
*/
public function __construct(UserSourceDirectorServiceInterface $userSourceDirectorService, RequestedRightServiceInterface $requestedRightService)
{
parent::__construct($userSourceDirectorService, $requestedRightService);
}
}

View File

@ -0,0 +1,10 @@
<?php
namespace App\Domain\RequestManagement;
/**
* @author kevinfrantz
*/
interface RequestedUserRightFacadeServiceInterface extends RequestedUserRightFacadeInterface
{
}

View File

@ -0,0 +1,23 @@
<?php
namespace tests\Unit\Domain\RequestManagement;
use PHPUnit\Framework\TestCase;
use App\Domain\RequestManagement\RequestedUserRightFacadeService;
use App\Domain\UserManagement\UserSourceDirectorServiceInterface;
use App\Domain\RequestManagement\RequestedUserRightFacadeServiceInterface;
use App\Domain\RequestManagement\RequestedRightServiceInterface;
/**
* @author kevinfrantz
*/
class RequestedUserRightFacadeServiceTest extends TestCase
{
public function testConstructorSet(): void
{
$requestedRightService = $this->createMock(RequestedRightServiceInterface::class);
$userSourceDirectorService = $this->createMock(UserSourceDirectorServiceInterface::class);
$service = new RequestedUserRightFacadeService($userSourceDirectorService, $requestedRightService);
$this->assertInstanceOf(RequestedUserRightFacadeServiceInterface::class, $service);
}
}