Show HN: Generate pytest API tests from an OpenAPI spec (openapi-test-generator.vercel.app)
Hi HN,
I built a tool that generates pytest API tests from an OpenAPI spec.
You can paste an OpenAPI URL and it generates a baseline pytest suite that hits each endpoint.
Live demo: https://openapi-test-generator.vercel.app/
GitHub: https://github.com/ryancrandall801/openapi-test-generator
1 comment
[ 4.4 ms ] story [ 10.4 ms ] threadRight now the generator parses the OpenAPI spec, extracts endpoints/methods, and creates pytest tests using the requests library.
The generated tests include basic status code assertions, but I'm experimenting with adding schema validation and better parameter coverage.
One thing I'm curious about: how people currently bootstrap API tests when starting a new service.