Skip to content
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

Get not hashed token for functional testing #267

Closed
SiestaCat opened this issue Aug 12, 2023 · 2 comments
Closed

Get not hashed token for functional testing #267

SiestaCat opened this issue Aug 12, 2023 · 2 comments
Labels
Feature New Feature Status: Reviewed Has been reviewed by a maintainer

Comments

@SiestaCat
Copy link

Hello

Is posible to retreive the not hashed token for functional testings?

regards

@jrushlow
Copy link
Collaborator

Howdy @SiestaCat - sorry for the slow reply. The best way to get the token is from the email itself.. I'm working on a PR in maker bundle to generate a functional test for reset-password. In the meantime, checkout a quick and dirty solution https://gist.github.com/jrushlow/193798c452a6e135c883273277e05621

@jrushlow jrushlow added Status: Reviewed Has been reviewed by a maintainer Feature New Feature labels Apr 28, 2024
@jrushlow
Copy link
Collaborator

This has feature has been added in MakerBundle - https://github.com/symfony/maker-bundle/releases/tag/v1.59.0 PR symfony/maker-bundle#1497

To generate a fully functional test - make:reset-password --with-tests. This will complain if you already have a say, ResetPasswordController::class. Checkout https://github.com/symfony/maker-bundle/blob/main/src/Resources/skeleton/resetPassword/Test.ResetPasswordController.tpl.php to see the actual test that MakerBundle generates...

Let us know if you run into any problems. Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature New Feature Status: Reviewed Has been reviewed by a maintainer
Projects
None yet
Development

No branches or pull requests

2 participants