Closed AlexMiao7 closed 2 years ago
I will help fix this soon
I have left some suggestions.
It is not a good idea to rely on data being manually entered in the database for the tests to pass.
what i was thinking is that I manually inserted some data into the databbase and try if i can search those data by id, and I also try to search some data which does not exist. So what else could I do in order to test the function?
I have left some suggestions. It is not a good idea to rely on data being manually entered in the database for the tests to pass.
what i was thinking is that I manually inserted some data into the databbase and try if i can search those data by id, and I also try to search some data which does not exist. So what else could I do in order to test the function?
The problem with that is new changes have all collection data in the test database wiped before each test and only the test database is used for tests.
Description
Adding three functions for user search by id/name/username using mongoose.
Related Issue
Solves #20
Type of change
How Has This Been Tested?
This schema has not been tested.
Checklist:
For more information, refer to the Contributing Guidelines document.