summaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
authorvladlosev <vladlosev@861a406c-534a-0410-8894-cb66d6ee9925>2010-04-22 11:44:59 (GMT)
committervladlosev <vladlosev@861a406c-534a-0410-8894-cb66d6ee9925>2010-04-22 11:44:59 (GMT)
commite05489605fc58736f837563db1fc33f9131ee810 (patch)
treeb6e3b13651c9f9d8a3405a3bcf292f6e2c6c68f0 /test
parente85375608b87ffd48fbc9c9f1f2d9a58176d7055 (diff)
downloadgoogletest-e05489605fc58736f837563db1fc33f9131ee810.zip
googletest-e05489605fc58736f837563db1fc33f9131ee810.tar.gz
googletest-e05489605fc58736f837563db1fc33f9131ee810.tar.bz2
Implements color output in GNU Screen sessions (issue 277).
Diffstat (limited to 'test')
-rw-r--r--test/gtest_unittest.cc9
1 files changed, 9 insertions, 0 deletions
diff --git a/test/gtest_unittest.cc b/test/gtest_unittest.cc
index a14f065..adc0fff 100644
--- a/test/gtest_unittest.cc
+++ b/test/gtest_unittest.cc
@@ -6264,8 +6264,17 @@ TEST(ColoredOutputTest, UsesColorsWhenTermSupportsColors) {
SetEnv("TERM", "xterm-color"); // TERM supports colors.
EXPECT_TRUE(ShouldUseColor(true)); // Stdout is a TTY.
+ SetEnv("TERM", "xterm-256color"); // TERM supports colors.
+ EXPECT_TRUE(ShouldUseColor(true)); // Stdout is a TTY.
+
+ SetEnv("TERM", "screen"); // TERM supports colors.
+ EXPECT_TRUE(ShouldUseColor(true)); // Stdout is a TTY.
+
SetEnv("TERM", "linux"); // TERM supports colors.
EXPECT_TRUE(ShouldUseColor(true)); // Stdout is a TTY.
+
+ SetEnv("TERM", "cygwin"); // TERM supports colors.
+ EXPECT_TRUE(ShouldUseColor(true)); // Stdout is a TTY.
#endif // GTEST_OS_WINDOWS
}