google/googletest

Question: Colored output on Windows powershell with CTest

Open

#2,930 opened on Jul 7, 2020

View on GitHub
 (2 comments) (2 reactions) (0 assignees)C++ (10,772 forks)batch import
help wanted

Repository metrics

Stars
 (38,603 stars)
PR merge metrics
 (Avg merge 7d 8h) (1 merged PR in 30d)

Description

I'm using CMake and CTest to build and run my tests.

On Linux I can produce color googletest output with CTest, like this: GTEST_COLOR=1 ctest -V

On Windows I tried something similar in powershell: $Env:GTEST_COLOR=1; ctest -V

However the output is still not colored. How can I achieve the desired colored output?

I'm using Googletest 1.10.0 and CMake 3.17.3

Contributor guide