NASA-IMPACT / veda-backend

Backend services for VEDA
Other
13 stars 5 forks source link

chore: test api responses against openapi spec #327

Closed stephenkilbourn closed 8 months ago

stephenkilbourn commented 8 months ago

What?

Currently, we test the api endpoints to ensure the correct response code (e.g. 200). This is a POC to use the open api validator to validate the response body against the stac open api spec. Currently, the docs are showing the response for these two endpoints as just any string. I've used a subset of the open api spec at https://api.stacspec.org/ to manually enter in a schema for now.

Testing?

these tests can be run locally with the existing shell script: ./scripts/run-local-tests.sh