engelsystem/tests/Unit/Http/Exceptions/HttpNotFoundTest.php

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

23 lines
626 B
PHP
Raw Normal View History

<?php
namespace Engelsystem\Test\Unit\Http\Exceptions;
use Engelsystem\Http\Exceptions\HttpNotFound;
use PHPUnit\Framework\TestCase;
class HttpNotFoundTest extends TestCase
{
/**
* @covers \Engelsystem\Http\Exceptions\HttpNotFound::__construct
*/
public function testConstruct(): void
{
$exception = new HttpNotFound();
$this->assertEquals(404, $exception->getStatusCode());
$this->assertEquals('', $exception->getMessage());
$exception = new HttpNotFound('Nothing to see here!');
$this->assertEquals('Nothing to see here!', $exception->getMessage());
}
}