© 2026 Hedgehog Software, LLC

TwitterGitHubDiscord
More
CommunitiesDocsAboutTermsPrivacy
Search
Star
Setup for Free
FilamentF
Filament•2y ago•
3 replies
Leonardy

How test resource flag --simple

I have a resource EquipmentOwnersResource that was created using the command sail artisan make:filament-resource EquipmentOwner --simple. This generates a single page for the resource instead of the typical 3 and puts the create/edit form in a modal instead of loading a new page.

I've create a Pest test as follows:

it('can create equipment owners', function () {

$equipmentOwner = EquipmentOwner::factory()->make();

livewire(ManageEquipmentOwners::class)
->set('name', $equipmentOwner->name)
->call('save')
->assertHasNoFormErrors();
});

However, when running the test I get an error "Unable to call component method. Public method [save] not found on component." I know this is because I'm not using the standard create/edit pages, but the Filament docs don't have an example of testing these "simple" resources.
Filament banner
FilamentJoin
A powerful open source UI framework for Laravel • Build and ship admin panels & apps fast with Livewire
20,307Members
Resources

Similar Threads

Was this page helpful?
Recent Announcements

Similar Threads

test `--simple` resource crud
FilamentFFilament / ❓┊help
15mo ago
How to test a simple resource CRUD functionality?
FilamentFFilament / ❓┊help
3y ago
How can I test a form from a modal? (simple resource)
FilamentFFilament / ❓┊help
2y ago
how to mutateFormDataBeforeCreate inside simple resource?
FilamentFFilament / ❓┊help
2y ago