You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Sometimes our example code is wrong and we can run it as part of CI to fix that.
Doctest
Our actual tests would stay where they are. The purpose of doctest would be to run example code in docstrings to make sure they execute. It has configurable pytest integration and can run against .rst files.
Example use case
In #973, there was a commit which had example code referencing a non-existent member of the pyglet module. Although it's an internal debug function, it would still make sense to check it. This even more important for user-facing example code and some of the doc.
I believe I configured this for arcade or another project at one point, so it should be a matter of copying config more than getting the technology working.
The text was updated successfully, but these errors were encountered:
This is worthwhile to pursue.
Many of the docstrings are missing code like import pyglet for brevity, so there will likely be lots of small updates to get things in line. We also want to take care not to add too much code to the docstrings. They are best for bare minimum, or "quick start" examples, and leave the detailed code to the programming guide.
TL;DR:
Sometimes our example code is wrong and we can run it as part of CI to fix that.
Doctest
Our actual tests would stay where they are. The purpose of
doctest
would be to run example code in docstrings to make sure they execute. It has configurable pytest integration and can run against.rst
files.Example use case
In #973, there was a commit which had example code referencing a non-existent member of the
pyglet
module. Although it's an internal debug function, it would still make sense to check it. This even more important for user-facing example code and some of the doc.I believe I configured this for arcade or another project at one point, so it should be a matter of copying config more than getting the technology working.
The text was updated successfully, but these errors were encountered: