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

Write Tests for users, clubs, stories #73

Merged
merged 24 commits into from
Jan 27, 2021

Conversation

HarishTeens
Copy link
Member

@HarishTeens HarishTeens commented Jan 25, 2021

Overview

  • Learn and set up end-to-end testing to test all well-implemented functions.
  • Write test for users, clubs and stories

This PR includes the following tests

Club

  • create a club with just name
  • update club with other info
  • update club with events
  • update a club with all other basic information
  • delete the above created club
  • Permission denied tests for Create, Update, Delete Club

Story

  • add a story (without link to an event)
  • add a story linked to an event
  • fetch current stories to get the above created stories
  • delete story
  • Permission denied tests for Add, Update and Delete Story
  • Author, event invalid
  • Author, event not found

User

  • Get all users
  • sign up a user + sign in the user and check level 1 authorisation
  • get users by username
  • get users by user id
  • update the created user with more information
  • update institute ID (NITR verification + Level 1=>Level 2 Bump)
  • Delete user
  • Delete user Not Found
  • Permission denied for for all queries and mutations

All the tests per file must execute sequentially as these tests are meant to mimic the real life flow of events in the same order.

Coverage Report

image

- tests for get all query
- test for authUser Mutation
- currentstories
- add story
- add club
- tested update user and fixed inconsistencies
- add documentation to user resolvers on the go
- add story
- fetch the added story from currentstories
- fix inconsistencies and sealproof stories workflow
- comment unused functions
- use resultResolver everywhere
- add club with just name
- update all other info
- delete the created club
@github-actions
Copy link

image image
Hello @HarishTeens , That's a great improvement to the code. Have a pinch of paitence while the reviewer gets impressed by the changes you made. Here are some doggos for company while you are waiting for the merge and marching ahead with your Hacktoberfest Contributions, Check your Dashboard for more information on Hacktoberfest. Stay safe 🚀 .

couldnt make all the tests independent since the uid is linked with server creation and cant be edited after tests start running
@github-actions
Copy link

image image
Hello @HarishTeens , That's a great improvement to the code. Have a pinch of paitence while the reviewer gets impressed by the changes you made. Here are some doggos for company while you are waiting for the merge and marching ahead with your Hacktoberfest Contributions, Check your Dashboard for more information on Hacktoberfest. Stay safe 🚀 .

@github-actions
Copy link

image image
Hello @HarishTeens , That's a great improvement to the code. Have a pinch of paitence while the reviewer gets impressed by the changes you made. Here are some doggos for company while you are waiting for the merge and marching ahead with your Hacktoberfest Contributions, Check your Dashboard for more information on Hacktoberfest. Stay safe 🚀 .

@github-actions
Copy link

image image
Hello @HarishTeens , That's a great improvement to the code. Have a pinch of paitence while the reviewer gets impressed by the changes you made. Here are some doggos for company while you are waiting for the merge and marching ahead with your Hacktoberfest Contributions, Check your Dashboard for more information on Hacktoberfest. Stay safe 🚀 .

@HarishTeens HarishTeens merged commit aedf779 into dscnitrourkela:development Jan 27, 2021
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.

3 participants