Skip to content
This repository has been archived by the owner on Oct 1, 2024. It is now read-only.

Commit

Permalink
If FORCE_COLOR is set, tell rich to force_terminal
Browse files Browse the repository at this point in the history
  • Loading branch information
AndydeCleyre committed Oct 7, 2022
1 parent ce9464d commit 12ba100
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion ward/_terminal.py
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,11 @@
"usedby": "#9285F6",
}
)
rich_console = Console(theme=theme, highlighter=NullHighlighter())
rich_console = Console(
theme=theme,
highlighter=NullHighlighter(),
force_terminal=True if "FORCE_COLOR" in os.environ else None,
)


def format_test_id(test_result: TestResult) -> str:
Expand Down

0 comments on commit 12ba100

Please sign in to comment.