- ✅ Receives a PUT request on /api/surveys/{survey_id}/results
- ✅ Validate if the request has been made by an user
- ✅ Validate the survey_id param
- ✅ Validate that answer field contains a valid answer
- ✅ Create a survey result with provided data it there is any survey result
- ✅ Update a survey result with provided data if it already exists one
- ✅ Returns 200 with the survey data
- ✅ Returns a 404 if the API doesn't exists
- ✅ Returns a 403 if it's not an user
- ✅ Returns a 403 if the provided user id is invalid
- ✅ Returns a 403 if the provided answer is invalid
- ✅ Returns a 500 if something goes wrong when trying to create a survey result
- ✅ Returns a 500 if something goes wrong when trying to update a survey
- ✅ Returns a 500 if something goes wrong when trying to load a surveys