Question about testing my OrderForm
I have an Order Form which I would like to test. So I have an OrderResource and the url to the form is:
So I wrote a test for this like so:
But when I run this I get:
Attempt to read property "form" on null.
MyCreateOrder class doesn't have a form property. I'm wondering where the $form property is set that renders the form when go to the aforementioned url
How can I solve this?
Thanks
admin/orders/create I believe that this corresponds to: 'create' => Pages\CreateOrder::route('/create'), So I wrote a test for this like so:
But when I run this I get:
Attempt to read property "form" on null.
at vendor/filament/forms/src/Testing/TestsForms.php:125
121▕ public function assertFormExists(): Closure
122▕ {
123▕ return function (string $name = 'form'): static {
124▕ /** @var ComponentContainer $form */
➜ 125▕ $form = $this->instance()->{$name};
126▕
127▕ $livewireClass = $this->instance()::class;
128▕
129▕ Assert::assertInstanceOf(
MyCreateOrder class doesn't have a form property. I'm wondering where the $form property is set that renders the form when go to the aforementioned url
How can I solve this?
Thanks