chore: code cleanup
This commit is contained in:
1 parent
1a3640b15c
commit
5a01054b0e
65 files changed
+1046
-795
No files matched your search
@@ -4,12 +4,12 @@ declare(strict_types=1);
|
||||
|
||||
namespace App\Tests\Controller;
|
||||
|
||||
use App\Booking\Horizon;
|
||||
use App\Booking\TimeRange;
|
||||
use App\Config\BookingHorizon;
|
||||
use App\Entity\Booking;
|
||||
use App\Entity\Resource;
|
||||
use App\Entity\ResourceType;
|
||||
use App\Entity\User;
|
||||
use App\Enum\ResourceType;
|
||||
use App\Model\TimeRange;
|
||||
use Doctrine\ORM\EntityManagerInterface;
|
||||
use Symfony\Bundle\FrameworkBundle\KernelBrowser;
|
||||
use Symfony\Bundle\FrameworkBundle\Test\WebTestCase;
|
||||
@@ -399,7 +399,7 @@ class BookingControllerTest extends WebTestCase
|
||||
public function testABookingBeyondTheHorizonIsRejected(): void
|
||||
{
|
||||
$this->client->loginUser($this->user('[email protected]'));
|
||||
$beyond = Horizon::latest()->modify('+1 day');
|
||||
$beyond = BookingHorizon::latest()->modify('+1 day');
|
||||
|
||||
$response = $this->submitBookingModal($this->resource('D1'), $beyond->format('Y-m-d'), ['allDay' => '1']);
|
||||
|
||||
@@ -411,7 +411,7 @@ class BookingControllerTest extends WebTestCase
|
||||
{
|
||||
$this->client->loginUser($this->user('[email protected]'));
|
||||
|
||||
$response = $this->submitBookingModal($this->resource('D1'), Horizon::latest()->format('Y-m-d'), ['allDay' => '1']);
|
||||
$response = $this->submitBookingModal($this->resource('D1'), BookingHorizon::latest()->format('Y-m-d'), ['allDay' => '1']);
|
||||
|
||||
self::assertSame(Response::HTTP_OK, $response->getStatusCode());
|
||||
}
|
||||
@@ -439,7 +439,7 @@ class BookingControllerTest extends WebTestCase
|
||||
public function testAnAdminIsNotBoundByTheHorizon(): void
|
||||
{
|
||||
$this->client->loginUser($this->admin('[email protected]'));
|
||||
$beyond = Horizon::latest()->modify('+2 months');
|
||||
$beyond = BookingHorizon::latest()->modify('+2 months');
|
||||
|
||||
$response = $this->submitBookingModal($this->resource('D1'), $beyond->format('Y-m-d'), ['allDay' => '1']);
|
||||
|
||||
|
||||
Reference in new issue
Block a user