-
Notifications
You must be signed in to change notification settings - Fork 67
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
Generated tests fail to preg_match the token #333
Comments
Hey Jeremy, If |
Hi, I assume the I don't know why, and maybe that's a misconfiguration in my case ? Or maybe it's because I'm using the messenger component to send the message asynchronously ? |
Seems like toString() calls Email::GenerateBody, which in turn creates a TextPart, which uses quoted-printable as the encoding. |
Version: 1.22.0
I used the maker bundle to generate tests for the password reset feature.
I adapted the code so that the mail is in french, but the generated code fails to properly get the token
Test method excerpt:
$email value excerpt:
Notice how the link is split in two lines.
In that case, only
qsfTOThd0P
matches as the token, which throws an InvalidResetPasswordTokenException because the length is not 40 inResetPasswordHelper::validateTokenAndFetchUser
Workaround:
instead of getting
toString()
of a templated message, we can get the raw text body, that doesn't have the formatting issue.The text was updated successfully, but these errors were encountered: