Commit 32d05841 authored by Cameron Pickett's avatar Cameron Pickett Committed by Facebook GitHub Bot

Fix CO_ASSERT_EQ for new gtest version

Differential Revision: D26882407

fbshipit-source-id: f7ab479aff6b8eaced65da333415efd33112ea0a
parent 8477e256
...@@ -149,11 +149,18 @@ ...@@ -149,11 +149,18 @@
#define CO_ASSERT_FALSE(condition) \ #define CO_ASSERT_FALSE(condition) \
GTEST_TEST_BOOLEAN_( \ GTEST_TEST_BOOLEAN_( \
!(condition), #condition, true, false, CO_GTEST_FATAL_FAILURE_) !(condition), #condition, true, false, CO_GTEST_FATAL_FAILURE_)
#if defined(GTEST_IS_NULL_LITERAL_)
#define CO_ASSERT_EQ(val1, val2) \ #define CO_ASSERT_EQ(val1, val2) \
CO_ASSERT_PRED_FORMAT2( \ CO_ASSERT_PRED_FORMAT2( \
::testing::internal::EqHelper<GTEST_IS_NULL_LITERAL_(val1)>::Compare, \ ::testing::internal::EqHelper<GTEST_IS_NULL_LITERAL_(val1)>::Compare, \
val1, \ val1, \
val2) val2)
#else
#define CO_ASSERT_EQ(val1, val2) \
CO_ASSERT_PRED_FORMAT2(::testing::internal::EqHelper::Compare, val1, val2)
#endif
#define CO_ASSERT_NE(val1, val2) \ #define CO_ASSERT_NE(val1, val2) \
CO_ASSERT_PRED_FORMAT2(::testing::internal::CmpHelperNE, val1, val2) CO_ASSERT_PRED_FORMAT2(::testing::internal::CmpHelperNE, val1, val2)
#define CO_ASSERT_LE(val1, val2) \ #define CO_ASSERT_LE(val1, val2) \
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment