conservancy / reimbursinator

Git Up GitHub: https://GiveUpGitHub.org
https://GiveUpGitHub.org
GNU Affero General Public License v3.0
7 stars 6 forks source link

Review error msg #117

Closed rupikad closed 5 years ago

rupikad commented 5 years ago

Fixed review api call to throw an error message when user tries to review a report that's already submitted.

Testing

  1. Update details in the .env file
  2. Run pipenv commands, and then python manage.py runserver
  3. Open postman and import the following link with updated endpoints: https://www.getpostman.com/collections/96e39a77bbd42ac92e13
  4. Login as frank and try "reviewing" the report in the database that's already submitted (should be report_pk = 8), and make sure you see the following output: { "message": "Cannot review a report that has already been submitted." }
  5. Try creating a new report, submit as finalized report, and reviewing after submitting and confirm you view the same output.