Skip to content

Commit cc2cfb7

Browse files
committed
Fixed tests running from pycharm
1 parent 0e21c5b commit cc2cfb7

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

progressbar/utils.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,9 @@ def is_ansi_terminal(
4747
is_terminal = True
4848
# This works for newer versions of pycharm only. older versions there
4949
# is no way to check.
50-
elif os.environ.get('PYCHARM_HOSTED') == '1':
50+
elif os.environ.get('PYCHARM_HOSTED') == '1' and not os.environ.get(
51+
'PYTEST_CURRENT_TEST'
52+
):
5153
is_terminal = True
5254

5355
if is_terminal is None:

0 commit comments

Comments
 (0)