LeNelSoN / you-are-the-hero

L'API dont vous êtes le héros is an interactive Java API that brings the adventure of "choose your own adventure" stories to life. Users can embark on unique journeys, make decisions at each step, and create dynamic narratives, all while experiencing the nostalgia of classic adventure books.
GNU General Public License v3.0
2 stars 10 forks source link

Write Unit Tests for AuthenticationService #10

Closed LeNelSoN closed 2 months ago

LeNelSoN commented 2 months ago

Quest:

Develop unit tests for the AuthenticationService class to ensure that user authentication works correctly and that JWTs are generated as expected.

Tasks:

Test authenticateUser Method:

image

The keeper of the repo 🏰

padabou commented 2 months ago

I'll take this one

padabou commented 2 months ago

Check that the generated token is valid and contains the expected username. ==> This is not a unit test because this feature is managed by another class