As a student, I should be able to get all possible programs, so that I can choose from them in while signing up #48
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 get all possible programs, so that I can choose from them in while signing up.Acceptance Criteria
GIVEN an
student
is requesting all possible programs in the appWHEN the app hits the
/programs
endpoint with a valid GET requestTHEN the app should receive a status
200
AND in the response, the following information should be returned:
Sample Request/Sample Response
Resources
Dev Notes
This endpoint is going to be accessible and work the same way for the admin as well.
Testing Notes
Scenario 1: GET request is successful
GIVEN a
student
is requesting all possible programs in the appWHEN the app hits the
/programs
endpoint with a valid GET requestTHEN the app should receive a status 200
AND the body should be an array
AND the first item of the array should be an object containing the following fields:
Scenario 2: GET request is unsuccessful
GIVEN a
student
is requesting all possible programs in the appWHEN the app hits the
/programs
endpoint with a valid GET requestTHEN the app should receive a status
404
AND the response headers'
code
parameter should contain "NotFoundException"Scenario 3: GET request is forbidden
GIVEN a
student
is requesting all possible programs in the appWHEN the app hits the
/programs
endpoint with a valid GET requestAND the request contains no authorization token
THEN the app should receive a status
401
AND the response headers'
code
parameter should contain "TokenMissingException"The text was updated successfully, but these errors were encountered: