diff --git a/tests/unit/test_exceptions.py b/tests/unit/test_exceptions.py index e3bf8fb4bae..8f8224dc817 100644 --- a/tests/unit/test_exceptions.py +++ b/tests/unit/test_exceptions.py @@ -63,7 +63,7 @@ def rendered_in_ascii(error: DiagnosticPipError, *, color: bool = False) -> str: with io.BytesIO() as stream: console = rich.console.Console( force_terminal=False, - file=io.TextIOWrapper(stream, encoding="ascii"), + file=io.TextIOWrapper(stream, encoding="ascii", newline=""), color_system="truecolor" if color else None, ) console.print(error)