We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent cea9e1d commit 54e2410Copy full SHA for 54e2410
Lib/test/libregrtest/setup.py
@@ -141,5 +141,9 @@ def setup_tests(runtests: RunTests) -> None:
141
142
random.seed(runtests.random_seed)
143
144
+ # sys.stdout is redirected to a StringIO in single process mode on which
145
+ # color auto-detect fails as StringIO is not a TTY. If the original
146
+ # sys.stdout supports color pass that through with FORCE_COLOR so that when
147
+ # results are printed, such as with -W, they get color.
148
if can_colorize(file=sys.stdout):
149
os.environ['FORCE_COLOR'] = "1"
0 commit comments