<?php

declare(strict_types=1);

use Illuminate\Foundation\Testing\RefreshDatabase;
use Illuminate\Support\Str;

uses(RefreshDatabase::class);

it('sets a dedicated session cookie name for /system', function () {
    $expectedCookieName = Str::slug((string) config('app.name', 'laravel')).'-system-session';

    $this->get('/system/login')
        ->assertSuccessful()
        ->assertCookie($expectedCookieName);
});
