filament
filament copied to clipboard
Next wizard step test helper
Description
This pull request creates a new test helper that calls for a wizard's next step
Closes #11622
Functional changes
Add the nextFormWizardStep()
action to the test component, optionally you can provide the $currentStep
(default 0) and $formName
(default 'form')
Sample:
use function Pest\Livewire\livewire;
it('moves to next wizard step', function () {
livewire(CreatePostUsingWizard::class)
->nextFormWizardStep()
->assertHasFormErrors(['title']);
});
- [x] Code style has been fixed by running the
composer cs
command. - [x] Changes have been tested to not break existing functionality.
- [x] Documentation is up-to-date.