From 6ee0581f426fcee4ba32218a78d2d75d412010dc Mon Sep 17 00:00:00 2001 From: Benjamin Kramer Date: Thu, 8 Aug 2013 11:17:39 +0000 Subject: [PATCH] Use EXPECT_TRUE/EXPECT_FALSE to avoid bogus warnings from the guts of gtest. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@187976 91177308-0d34-0410-b5e6-96231b3b80d8 --- unittests/Support/LocaleTest.cpp | 38 ++++++++++++++++---------------- 1 file changed, 19 insertions(+), 19 deletions(-) diff --git a/unittests/Support/LocaleTest.cpp b/unittests/Support/LocaleTest.cpp index ad90bdf9f54..81d31b9f613 100644 --- a/unittests/Support/LocaleTest.cpp +++ b/unittests/Support/LocaleTest.cpp @@ -67,33 +67,33 @@ TEST(Locale, columnWidth) { } TEST(Locale, isPrint) { - EXPECT_EQ(false, isPrint(0)); // - - EXPECT_EQ(false, isPrint(0x01)); - EXPECT_EQ(false, isPrint(0x1F)); - EXPECT_EQ(true, isPrint(' ')); - EXPECT_EQ(true, isPrint('A')); - EXPECT_EQ(true, isPrint('~')); - EXPECT_EQ(false, isPrint(0x7F)); // .. - EXPECT_EQ(false, isPrint(0x90)); - EXPECT_EQ(false, isPrint(0x9F)); + EXPECT_FALSE(isPrint(0)); // - + EXPECT_FALSE(isPrint(0x01)); + EXPECT_FALSE(isPrint(0x1F)); + EXPECT_TRUE(isPrint(' ')); + EXPECT_TRUE(isPrint('A')); + EXPECT_TRUE(isPrint('~')); + EXPECT_FALSE(isPrint(0x7F)); // .. + EXPECT_FALSE(isPrint(0x90)); + EXPECT_FALSE(isPrint(0x9F)); - EXPECT_EQ(true, isPrint(0xAC)); - EXPECT_EQ(true, isPrint(0xAD)); // SOFT HYPHEN is displayed on most terminals - // as either a space or a dash. - EXPECT_EQ(true, isPrint(0xAE)); + EXPECT_TRUE(isPrint(0xAC)); + EXPECT_TRUE(isPrint(0xAD)); // SOFT HYPHEN is displayed on most terminals + // as either a space or a dash. + EXPECT_TRUE(isPrint(0xAE)); // MacOS implementation doesn't think it's printable. #ifndef __APPLE__ - EXPECT_EQ(true, isPrint(0x0377)); // GREEK SMALL LETTER PAMPHYLIAN DIGAMMA + EXPECT_TRUE(isPrint(0x0377)); // GREEK SMALL LETTER PAMPHYLIAN DIGAMMA #endif // __APPLE__ - EXPECT_EQ(false, isPrint(0x0378)); // .. + EXPECT_FALSE(isPrint(0x0378)); // .. - EXPECT_EQ(false, isPrint(0x0600)); // ARABIC NUMBER SIGN + EXPECT_FALSE(isPrint(0x0600)); // ARABIC NUMBER SIGN - EXPECT_EQ(false, isPrint(0x1FFFF)); // .. - EXPECT_EQ(true, isPrint(0x20000)); // CJK UNIFIED IDEOGRAPH-20000 + EXPECT_FALSE(isPrint(0x1FFFF)); // .. + EXPECT_TRUE(isPrint(0x20000)); // CJK UNIFIED IDEOGRAPH-20000 - EXPECT_EQ(false, isPrint(0x10FFFF)); // noncharacter + EXPECT_FALSE(isPrint(0x10FFFF)); // noncharacter } #endif // _WIN32