FilamentF
Filament10mo ago
frame

Testing ListResources page with tenancy (missing parameter: tenant)

What am I missing here? 🤔
test('lists groups', function () {
    livewire(GroupResource\Pages\ListGroups::class, [
        'tenant' => $this->client->uuid,
    ])->assertOk();
});

Missing required parameter for [Route: filament.instructors.resources.groups.index] [URI: instructors/{tenant}/groups] [Missing parameter: tenant]

GET|HEAD   instructors/{tenant}/groups ... filament.instructors.resources.groups.index › App\Filament\Instructors\Resources\GroupResource\Pages\ListGroups
Solution
Tenant is set separately not as a parameter to livewire
Filament::setTenant($this->client);
Was this page helpful?