A POST request can be sent to /education/ endpoint.
Given a JSON body with accountID, degreeName, and collegeName, a new Education row will be created and connected with an EducationBridge row to the account specified by the accountID. An empty optionalDescription will be created if not specified in the request.
I created tests in education_tests.py for error handling and creating a successful POST request.
I don't remember in which issue I saw this comment, but it was suggested that the fields for EducationBridge be changed so that an account can have multiple educations. However, because this isn't the case for now, I did not create any checks for any duplicate education rows because trying to test for these raises an integrity error in the server.
#32
A POST request can be sent to /education/ endpoint.
Given a JSON body with accountID, degreeName, and collegeName, a new Education row will be created and connected with an EducationBridge row to the account specified by the accountID. An empty optionalDescription will be created if not specified in the request.
I created tests in education_tests.py for error handling and creating a successful POST request.
I don't remember in which issue I saw this comment, but it was suggested that the fields for EducationBridge be changed so that an account can have multiple educations. However, because this isn't the case for now, I did not create any checks for any duplicate education rows because trying to test for these raises an integrity error in the server.