Overview
Add pytest as a testing framework and create several tests for each API endpoint.
Details
- Add pytest as a testing framework
- Create unit tests to check querying db, if a basic response returned is 200 for a valid API call, and error handling for invalid requests
- Create about 5 integration tests for each API endpoint with both valid and invalid requests (
/subjects, /courses, /courses/{cid})
Why would this feature be useful?
To ensure no regressions.
Additional Notes
Some previous work has been done at #15.
#65 should be fixed first to ensure correct response codes.
Overview
Add pytest as a testing framework and create several tests for each API endpoint.
Details
/subjects,/courses,/courses/{cid})Why would this feature be useful?
To ensure no regressions.
Additional Notes
Some previous work has been done at #15.
#65 should be fixed first to ensure correct response codes.