OpenTree-Education / rhizone-lms

A learning management system focused on self-reflection.
https://rhi.zone
BSD 3-Clause Clear License
14 stars 7 forks source link

There needs to be a test for the GET /:assessmentId/submissions/:submissionId route #538

Closed mays4 closed 1 year ago

mays4 commented 1 year ago

Describe the Feature / Enhancement

There needs to be a test for the GET /assessments/:assessmentId/submissions/:submissionId route (from the router file), which currently does not exist. We need to test this route to ensure the code written for the test will behave as expected by the protocol we previously defined.

This issue continues the work from issue #515.

Additional Details and Resources

This route requires URL parameters of assessmentId (the ID of a program assessment) and submissionId (the ID of a assessment submission) and expects no body in the request. The response should contain the following:

Facilitator

itemEnvelope({
  "curriculum_assessment": CurriculumAssessment, (with 'questions' and 'answers' and correct answers)
  "program_assessment": ProgramAssessment,
  "assessment_submission": AssessmentSubmission (with 'responses')
});

Participant

itemEnvelope({
  "curriculum_assessment": CurriculumAssessment, (with 'questions' and 'answers' and correct answers (only if graded))
  "program_assessment": ProgramAssessment,
  "assessment_submission": AssessmentSubmission (with 'responses')
});

Correct Project Selected

Labels