-
-
Notifications
You must be signed in to change notification settings - Fork 2.2k
Add configuration options to duration
extension
#13469
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
base: master
Are you sure you want to change the base?
Conversation
This is ready but I don't think I have the tests configured properly. When I run each test individually locally they each pass on their own. But running the whole suite causes some to fail. Is there some kind of interaction between tests? |
duration
extension with configuration optionsduration
extension
Please add yourself to AUTHORS too. I think it's better to add each option as a new top-level option rather than as a dictionary. |
I'm going to modify the API a bit to better match pytest. |
I've also added a new option to limit the duration to some value. Should be ready now. CI is green except there are seemingly unrelated |
Purpose
The duration extension is great but is not configurable. It currently only shows 5 slowest durations and only
prints to the console.
This PR adds configuration options:
duration_n_slowest
to print any number of durations to console (not just 5)duration_print_slowest
to enable/disable printing to console altogetherduration_write_json
to write all durations to a JSON fileduration_print_total
to print the total read time to consoleduration_limit
to emit a warning for long durations above the limitNo tests are yet included.I am a first time contributor and not familiar with dev tools and conventions here... I may need some extra help.