create(['role' => 'super_admin']); $tenant = Tenant::factory()->create([ 'last_activity_at' => now()->subDay(), 'pending_deletion_at' => now()->addDays(10), 'deletion_warning_sent_at' => now()->subHours(2), ]); TenantNotificationLog::query()->create([ 'tenant_id' => $tenant->id, 'type' => 'retention_warning', 'channel' => 'mail', 'recipient' => 'owner@example.com', 'status' => 'sent', 'context' => ['source' => 'test'], 'sent_at' => now()->subHour(), ]); $this->actingAs($user, 'super_admin'); $url = TenantResource::getUrl('lifecycle', ['record' => $tenant], panel: 'superadmin'); $this->get($url) ->assertOk() ->assertSee(__('admin.tenants.timeline.created')) ->assertSee(__('admin.tenants.timeline.deletion_scheduled')) ->assertSee(__('admin.tenants.timeline.notification_sent')); } }