fix(service): defer stop when pulling latest images

Ensure restart actions flow through StartService so pull-latest restarts can
avoid stopping the service before image pulls. Also raise the changelog modal
above the desktop sidebar toggle.
This commit is contained in:
Andras Bacsai committed 2026-05-31 21:19:18 +02:00
1 parent 38e855b20e
commit c9fcc0bc44
6 files changed
+94 -11

No files matched your search

+44
View File
@@ -0,0 +1,44 @@
<?php
use App\Livewire\SettingsDropdown;
use App\Models\User;
use App\Services\ChangelogService;
use Illuminate\Support\Carbon;
use Illuminate\Support\Collection;
use Illuminate\Support\Facades\Auth;
use Livewire\Livewire;
it('renders the changelog modal above the desktop sidebar toggle', function () {
$user = new User(['email' => 'test@example.com']);
$user->id = 1;
Auth::setUser($user);
app()->instance(ChangelogService::class, new class extends ChangelogService
{
public function getEntriesForUser(User $user): Collection
{
return collect([
(object) [
'tag_name' => 'v1.0.0',
'title' => 'Test Release',
'content' => 'Release notes',
'content_html' => '<p>Release notes</p>',
'published_at' => Carbon::parse('2026-05-01'),
'is_read' => false,
],
]);
}
public function getUnreadCountForUser(User $user): int
{
return 1;
}
});
Livewire::test(SettingsDropdown::class, ['trigger' => 'changelog-sidebar'])
->call('openWhatsNewModal')
->assertSee('Changelog')
->assertSee('z-[60]', false)
->assertSee('closeWhatsNewModal', false);
});