This is a how-to/best-practice question.
- I have a code base with a suite of unit tests run with
pytest
- I have a set of
*.rst
files which provide explanation of each test, along with a table of results and images of some mathematical plots - Each time the pytest suite runs, it dynamically updates the
*.rst
files with the results of the latest test data, updating numerical values, time-stamping the tests, etc
I would like to integrate this with the project docs. I could
- Build these rst files separately with
sphinx-build
whenever I want to view the test results [this seems bad, since it's labor intensive and not automated] - tell Sphinx to render these pages separately and include them in the project docs [better, but I'm not sure how to configure this]
- have a separate set of sphinx docs for the test results which I can build after each run of the test suite
Which approach (or another approach) is most effective? Is there a best practice for doing this type of thing?