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

Assign blocks names that are printed in pytest output? #72

Closed
naten7k opened this issue Jan 16, 2022 · 2 comments · Fixed by #73
Closed

Assign blocks names that are printed in pytest output? #72

naten7k opened this issue Jan 16, 2022 · 2 comments · Fixed by #73

Comments

@naten7k
Copy link

naten7k commented Jan 16, 2022

First off, this package is awesome, thank you for putting it together! As a longtime R knitr/sweave user, this fills a massive hole in python for me (different use case, but conceptually similar).

I was wondering if there was any way to add block names to each code block, so that when I run pytest, I can easily tell which tests are which? Right now, it's a little tricky to visually parse this:

============================= test session starts ==============================
platform linux -- Python 3.9.6, pytest-6.2.5, py-1.11.0, pluggy-1.0.0 -- /usr/local/bin/python3
cachedir: .pytest_cache
rootdir: /builds/neuralink/sw/util/python_packages/nlk_utils_n1plot
plugins: codeblocks-0.12.2
collecting ... collected 20 items
README.md::README.md PASSED                                              [  5%]
README.md::README.md PASSED                                              [  5%]
README.md::README.md PASSED                                              [  5%]
README.md::README.md PASSED                                              [  5%]
README.md::README.md PASSED                                              [  5%]
README.md::README.md PASSED                                              [  5%]
README.md::README.md PASSED                                              [  5%]
README.md::README.md PASSED                                              [  5%]
README.md::README.md PASSED                                              [  5%]

Also apologies if this isn't an issue, happy to move this somewhere else if need be.

Thanks again!

@nschloe nschloe mentioned this issue Jan 17, 2022
@nschloe
Copy link
Owner

nschloe commented Jan 17, 2022

This is fixed in #73. Test names now include line numbers, e.g.,

README.md::line 56

Will release shortly.

@nschloe nschloe closed this as completed Jan 17, 2022
@naten7k
Copy link
Author

naten7k commented Jan 18, 2022

you are awesome, thank you!!!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants