[2.x] Use correct feature flag in password reset tests #881
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
What?
In the fortify routes file, all the routes being tested in both PHPUnit and Pest variants of
PasswordResetTest
are only exposed using the following condition (see here):If the reset-passwords feature flag is disabled, this causes the published test files for
PasswordResetTest
to fail, regardless of the preferred testing framework used.This PR updates both
PasswordResetTest
variants to use the correct feature flag,Features::resetPasswords()
instead ofFeatures::updatePasswords()
which is currently being used incorrectly.Why?
I installed a fresh Laravel project with Jetstream using the
2.x-dev
branch on packagist to keep one of my packages up-to-date with recent merges / changes. Upon publishing the pest tests and disabling password resets, my CI pipeline broke.Replicate the problem
You can replicate this on
2.x-dev
yourself locally. First, select your stack and publish all files (including tests). Then inconfig/fortify.php
comment out this line:Then run your test suite and see the
PasswordResetTest
's fail.