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

Add unit test for getUsers by ID #62

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

multi-vit
Copy link

Added a unit test in /server/test/controller/User.test.js for getUser with an ID.
This identified a bug on line 22 of /server/src/controller/user.controller.js where the conditional check was for !user, when it should have been !users.
Fixed this and test is now passing.
If you're happy with this PR, I'll happily try and add more tests for the other controllers/services. Just wanted to try one first to make sure it was ok!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant