refactor: apply rector
Some checks are pending
tests / ci (push) Waiting to run

This commit is contained in:
Benjamin Nussbaum 2025-09-24 20:31:32 +02:00
parent c67a182cf2
commit b4b6286172
89 changed files with 672 additions and 666 deletions

View file

@ -4,7 +4,7 @@ use App\Models\Device;
use App\Models\Playlist;
use App\Models\PlaylistItem;
test('playlist has required attributes', function () {
test('playlist has required attributes', function (): void {
$playlist = Playlist::factory()->create([
'name' => 'Test Playlist',
'is_active' => true,
@ -21,7 +21,7 @@ test('playlist has required attributes', function () {
->active_until->format('H:i')->toBe('17:00');
});
test('playlist belongs to device', function () {
test('playlist belongs to device', function (): void {
$device = Device::factory()->create();
$playlist = Playlist::factory()->create(['device_id' => $device->id]);
@ -30,7 +30,7 @@ test('playlist belongs to device', function () {
->id->toBe($device->id);
});
test('playlist has many items', function () {
test('playlist has many items', function (): void {
$playlist = Playlist::factory()->create();
$items = PlaylistItem::factory()->count(3)->create(['playlist_id' => $playlist->id]);
@ -39,7 +39,7 @@ test('playlist has many items', function () {
->each->toBeInstanceOf(PlaylistItem::class);
});
test('getNextPlaylistItem returns null when playlist is inactive', function () {
test('getNextPlaylistItem returns null when playlist is inactive', function (): void {
$playlist = Playlist::factory()->create(['is_active' => false]);
expect($playlist->getNextPlaylistItem())->toBeNull();