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

Added tests for answered by instructor feature backend #42

Merged
merged 16 commits into from
Oct 11, 2024

Conversation

lukenalewajk
Copy link

@lukenalewajk lukenalewajk commented Oct 11, 2024

Added a test in the test/topic.js file to check for the presence of the added-by-instructor feature from file src/topic/post.js. Checks for the presence of the answeredByProf variable. No next steps required.

@etong11 etong11 added this to the Sprint 2 milestone Oct 11, 2024
@coveralls
Copy link

Pull Request Test Coverage Report for Build 11284485763

Warning: This coverage report may be inaccurate.

This pull request's base commit is no longer the HEAD commit of its target branch. This means it includes changes from outside the original pull request, including, potentially, unrelated coverage changes.

Details

  • 7 of 7 (100.0%) changed or added relevant lines in 2 files are covered.
  • 44 unchanged lines in 7 files lost coverage.
  • Overall coverage increased (+0.009%) to 82.683%

Files with Coverage Reduction New Missed Lines %
src/posts/summary.js 1 93.33%
src/controllers/write/topics.js 1 96.09%
src/posts/create.js 2 94.44%
src/topics/events.js 5 92.5%
src/api/topics.js 7 86.88%
src/topics/posts.js 12 85.18%
src/topics/tools.js 16 82.53%
Totals Coverage Status
Change from base Build 11244895282: 0.009%
Covered Lines: 22379
Relevant Lines: 25641

💛 - Coveralls

Copy link

@ldlin1 ldlin1 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The changes look good! The modifications made to the schema and functions seem to make the functionality more stable/testable. The test looks good for checking whether a post has been answered by an admin.

@ldlin1 ldlin1 merged commit 14cabac into f24 Oct 11, 2024
1 check passed
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.

5 participants