F
Filament14mo ago
fasna

Test visible elements in Infolist

I'm trying to write testcases for the Infolist in my index page of resources. I copuldn't find any documentation on that, I can load the component. No idea, how can I proceed further? Need to assert, whether I can see the correct record and field names. Here is my test code:
test('user can view an individual user', function () {
$user = User::get()->first();
$testable = livewire(ListUsers::class)
->callTableAction('view', $user);
$testable->instance()->getInfolist('infolist');
});
test('user can view an individual user', function () {
$user = User::get()->first();
$testable = livewire(ListUsers::class)
->callTableAction('view', $user);
$testable->instance()->getInfolist('infolist');
});
0 Replies
No replies yetBe the first to reply to this messageJoin
Want results from more Discord servers?
Add your server