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

[5.7] allow 'assertJsonMissingValidationErrors' to be called without an argument #27176

merged 2 commits into from Jan 16, 2019


None yet
2 participants
Copy link

SjorsO commented Jan 15, 2019

This PR is a different implementation of #27172

This PR makes calling assertJsonMissingValidationErrors without an argument behave the same as as assertSessionHasNoErrors() (but it works for Json responses, since they don't store their errors in session).


$this->post(route(''), $data)

If this test has validation errors, it will print them to the console. If you would write the same test without the assertJsonMissingValidationErrors(), and then you get validation errors, the test will only print an unhelpful "expected status 201 but received 422".

SjorsO and others added some commits Jan 15, 2019

@taylorotwell taylorotwell merged commit 990d867 into laravel:5.7 Jan 16, 2019

1 of 2 checks passed

continuous-integration/travis-ci/pr The Travis CI build is in progress
continuous-integration/styleci/pr The analysis has passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment