Unit tests for progress bar in pytest #1093
-
I have been working on adding To rule out that it was something in my wrappers that was the issue, I created some very simple unit tests: one with Can anyone help explain what I need to do to properly capture the output from the progress bar? Oh, I also tried creating a
|
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
Hi Ed, I think I know what is going on. Rich will hide things like progress bars if it detects it is not writing to a terminal. This is because you don't want all the frames of progress bars written out if you are piping to a file for example. You can add |
Beta Was this translation helpful? Give feedback.
Hi Ed,
I think I know what is going on. Rich will hide things like progress bars if it detects it is not writing to a terminal. This is because you don't want all the frames of progress bars written out if you are piping to a file for example.
You can add
force_terminal=True
to the Console constructor to bypass that and render the progress bars.