Skip to content

[12.x] Document assertRedirectBackWithErrors and assertRedirectBackWithoutErrors #10499

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Draft
wants to merge 1 commit into
base: 12.x
Choose a base branch
from

Conversation

AhmedAlaa4611
Copy link
Contributor

Description

This PR adds documentation for the new test response assertions:

  • assertRedirectBackWithErrors(): a convenience method that combines assertRedirectBack() and assertSessionHasErrors().

  • assertRedirectBackWithoutErrors(): a convenience method that combines assertRedirectBack() and assertSessionHasNoErrors().

Both methods help improve test readability when working with validation redirections.

I avoided repeating the full parameter explanation by pointing to the assertSessionHasErrors() method.

Related PR

laravel/framework#55987

@AhmedAlaa4611 AhmedAlaa4611 marked this pull request as draft June 12, 2025 18:00
@AhmedAlaa4611
Copy link
Contributor Author

Drafting until release day.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant