Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Automate testing of code in docstrings #7072

Open
masci opened this issue Feb 23, 2024 · 2 comments
Open

Automate testing of code in docstrings #7072

masci opened this issue Feb 23, 2024 · 2 comments
Labels
type:documentation Improvements on the docs

Comments

@masci
Copy link
Contributor

masci commented Feb 23, 2024

Let's automate testing code in docstrings - https://docs.python.org/3/library/doctest.html

@masci masci added type:documentation Improvements on the docs P1 High priority, add to the next sprint labels Feb 23, 2024
@masci masci added this to the 2.0.0 milestone Feb 23, 2024
@shadeMe
Copy link
Collaborator

shadeMe commented Feb 26, 2024

Superseded by #7074, so let's make this one about adding automated testing.

@shadeMe shadeMe changed the title Add code examples in components' run() method Automate testing of code in docstrings Feb 26, 2024
@silvanocerza
Copy link
Contributor

Putting this back in the backlog after some discussion.

We thought it would be simpler to add testing of docstrings snippets but is not.
We'd have to change how we define the snippets as doctest expects a specific format, or create our own parser.

Another issue would be handling secrets in some examples too.

@silvanocerza silvanocerza added P3 Low priority, leave it in the backlog and removed P1 High priority, add to the next sprint labels Feb 27, 2024
@shadeMe shadeMe removed this from the 2.0.0 milestone Feb 27, 2024
@masci masci removed the P3 Low priority, leave it in the backlog label May 10, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type:documentation Improvements on the docs
Projects
None yet
Development

No branches or pull requests

3 participants