[DELETE] A Class #181
Labels
Status: Completed
Type: Feature
user story
A brief explanation of a functionality or an interaction with the system, from a user's perspective
Summary
As a
student
, I should be able to delete classes, so that I can remove old or inconsistent entries.Acceptance Criteria
GIVEN a
student
is deleting an class in the appWHEN the app hits the
/classes/:term_id/:class_erp
endpoint with a valid DELETE request, containing the path parameter::class_erp
, the unique id of the entity being removed.THEN the app should receive a status
200
AND in the response, the following information should be returned:
Sample Request/Sample Response
Resources
Dev Notes
{Some complementary notes if necessary}
Testing Notes
Scenario 1: DELETE request is successful (Admin):
/classes
endpoint using anadmin
account token and ensure a200
status code is returned./classes/:term_id/:class_erp
endpoint using anadmin
account token and ensure a200
status code is returned./classes/:term_id/:class_erp
endpoint should return a status code404
.code
parameter should contain "NotFoundException".Scenario 2: DELETE request is unsuccessful due to unknown class_erp
/classes/:term_id/:class_erp
endpoint containing a non-existentclass_erp
.404
status code is returned.code
parameter should contain "NotFoundException".Scenario 3: DELETE request is forbidden
/classes/:term_id/:class_erp
endpoint for usingstudent
account token.403
forbidden status code.code
parameter should contain "ForbiddenException"Scenario 4: DELETE request is unauthorized
/classes/:term_id/:class_erp
endpoint without an authorization token401
unauthorized status code is returned.code
parameter should contain "TokenMissingException"The text was updated successfully, but these errors were encountered: