You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
29 lines
748 B
PHTML
29 lines
748 B
PHTML
6 years ago
|
<?php
|
||
|
|
||
|
namespace Unit\Controllers;
|
||
|
|
||
|
use Engelsystem\Controllers\CreditsController;
|
||
|
use Engelsystem\Http\Response;
|
||
|
use PHPUnit\Framework\MockObject\MockObject;
|
||
|
use PHPUnit\Framework\TestCase;
|
||
|
|
||
|
class CreditsControllerTest extends TestCase
|
||
|
{
|
||
|
/**
|
||
|
* @covers \Engelsystem\Controllers\CreditsController::__construct
|
||
|
* @covers \Engelsystem\Controllers\CreditsController::index
|
||
|
*/
|
||
|
public function testIndex()
|
||
|
{
|
||
|
/** @var Response|MockObject $response */
|
||
|
$response = $this->createMock(Response::class);
|
||
|
|
||
|
$response->expects($this->once())
|
||
|
->method('withView')
|
||
|
->with('pages/credits.twig');
|
||
|
|
||
|
$controller = new CreditsController($response);
|
||
|
$controller->index();
|
||
|
}
|
||
|
}
|