There was a production incident last week on OpenFisca France, where an inadequate config key prevented the Web API from starting altogether. This would have been caught if the CI had a small test for the web API.
I thus suggest to add a smoke test to the web API, which will check:
The API starts with openfisca serve.
Accessing the swagger endpoint returns an HTTP 200 code.
The result of the swagger endpoint is valid JSON.
This test result should appear as a dedicated step in each PR, along with check_version_and_changelog or lint_yaml_files.
There was a production incident last week on OpenFisca France, where an inadequate config key prevented the Web API from starting altogether. This would have been caught if the CI had a small test for the web API.
I thus suggest to add a smoke test to the web API, which will check:
openfisca serve
.swagger
endpoint returns an HTTP 200 code.swagger
endpoint is valid JSON.This test result should appear as a dedicated step in each PR, along with
check_version_and_changelog
orlint_yaml_files
.