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

test: add test for all models using chai & mocha #200

Open
AmanNegi opened this issue Oct 17, 2024 · 3 comments
Open

test: add test for all models using chai & mocha #200

AmanNegi opened this issue Oct 17, 2024 · 3 comments
Labels
backend Backend (Node/Express) Related Task good first issue Good for newcomers hacktoberfest-accepted help wanted Extra attention is needed

Comments

@AmanNegi
Copy link
Owner

Description

Currently, tests are written for src/models/cart.js and src/models/comment.js. Further we require to create tests for other models. Which are namely:

  1. src/models/user.js : User Model
  2. src/models/millet_item.js: Millet Item Model

For reference you can see the tests written for models under /src/tests. Feel free to query about any doubts.

@AmanNegi AmanNegi added help wanted Extra attention is needed good first issue Good for newcomers hacktoberfest-accepted backend Backend (Node/Express) Related Task labels Oct 17, 2024
@STXRSHIVA
Copy link

Hey @AmanNegi i tried to create a test file for src/models/user.js but i had been getting failed tests and the other file for src/models/millet_item.js i had successfully created a test file for it with no issues but i only have problem with the user.js test file

Screenshot 2024-10-22 233911

these are the test cases which i been failing

Screenshot 2024-10-22 234058

and also made some changes in the validateSignUp

Screenshot 2024-10-22 234559

can you help me out with this

and test cases results for the millet-item.js

Screenshot 2024-10-22 234802

@AmanNegi
Copy link
Owner Author

Could you create a PR so that I can review what changes you have exactly made, and test it on my system.

@STXRSHIVA
Copy link

sure

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backend Backend (Node/Express) Related Task good first issue Good for newcomers hacktoberfest-accepted help wanted Extra attention is needed
Projects
Status: No status
Development

No branches or pull requests

2 participants