In this super quick episode, we tidy up a small but important detail in our email sending tests. Previously, when we were checking details of the sent email (like the token), we accidentally used assignment (=
) instead of a strict equality check. While this didn't break our tests when run in isolation, it's important to always perform proper comparisons, especially for key values like verification tokens.
So, in this video, we make a quick fix: we change our test so that instead of assigning, we're actually checking with strict equality. After updating, we re-run our test to make sure everything still passes, and we're all good!
The main takeaway here is to always use strict checks when validating values in your tests, to avoid accidental passes!