diff options
author | glider@chromium.org <glider@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-03-18 10:25:57 +0000 |
---|---|---|
committer | glider@chromium.org <glider@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-03-18 10:25:57 +0000 |
commit | 3d8d7d46ac4f3ea7a14a742c52b705cdedc04ac7 (patch) | |
tree | d1c843a39bd423b24ef6d9b0aa7ffb500e352666 /third_party/tcmalloc/chromium/src/base/logging.h | |
parent | 2fbc71c029729406251fcde14ff1845d74dd974d (diff) | |
download | chromium_src-3d8d7d46ac4f3ea7a14a742c52b705cdedc04ac7.zip chromium_src-3d8d7d46ac4f3ea7a14a742c52b705cdedc04ac7.tar.gz chromium_src-3d8d7d46ac4f3ea7a14a742c52b705cdedc04ac7.tar.bz2 |
Merged third_party/tcmalloc/vendor/src(google-perftools r87) into
third_party/tcmalloc/chromium/src.
Review URL: http://codereview.chromium.org/576001
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@41938 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'third_party/tcmalloc/chromium/src/base/logging.h')
-rw-r--r-- | third_party/tcmalloc/chromium/src/base/logging.h | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/third_party/tcmalloc/chromium/src/base/logging.h b/third_party/tcmalloc/chromium/src/base/logging.h index 3313d97..4d5e30c 100644 --- a/third_party/tcmalloc/chromium/src/base/logging.h +++ b/third_party/tcmalloc/chromium/src/base/logging.h @@ -136,17 +136,26 @@ enum { DEBUG_MODE = 1 }; #define CHECK_GE(val1, val2) CHECK_OP(>=, val1, val2) #define CHECK_GT(val1, val2) CHECK_OP(> , val1, val2) -// A synonym for CHECK_* that is used in some unittests. +// Synonyms for CHECK_* that are used in some unittests. #define EXPECT_EQ(val1, val2) CHECK_EQ(val1, val2) #define EXPECT_NE(val1, val2) CHECK_NE(val1, val2) #define EXPECT_LE(val1, val2) CHECK_LE(val1, val2) #define EXPECT_LT(val1, val2) CHECK_LT(val1, val2) #define EXPECT_GE(val1, val2) CHECK_GE(val1, val2) #define EXPECT_GT(val1, val2) CHECK_GT(val1, val2) +#define ASSERT_EQ(val1, val2) EXPECT_EQ(val1, val2) +#define ASSERT_NE(val1, val2) EXPECT_NE(val1, val2) +#define ASSERT_LE(val1, val2) EXPECT_LE(val1, val2) +#define ASSERT_LT(val1, val2) EXPECT_LT(val1, val2) +#define ASSERT_GE(val1, val2) EXPECT_GE(val1, val2) +#define ASSERT_GT(val1, val2) EXPECT_GT(val1, val2) // As are these variants. #define EXPECT_TRUE(cond) CHECK(cond) #define EXPECT_FALSE(cond) CHECK(!(cond)) #define EXPECT_STREQ(a, b) CHECK(strcmp(a, b) == 0) +#define ASSERT_TRUE(cond) EXPECT_TRUE(cond) +#define ASSERT_FALSE(cond) EXPECT_FALSE(cond) +#define ASSERT_STREQ(a, b) EXPECT_STREQ(a, b) // Used for (libc) functions that return -1 and set errno #define CHECK_ERR(invocation) PCHECK((invocation) != -1) |