Loading liblog/tests/liblog_test.cpp +0 −15 Original line number Original line Diff line number Diff line Loading @@ -3004,21 +3004,6 @@ TEST(liblog, create_android_logger_overflow) { EXPECT_LE(0, android_log_destroy(&ctx)); EXPECT_LE(0, android_log_destroy(&ctx)); ASSERT_TRUE(NULL == ctx); ASSERT_TRUE(NULL == ctx); } } TEST(liblog, android_log_write_list_buffer) { __android_log_event_list ctx(1005); ctx << 1005 << "tag_def" << "(tag|1),(name|3),(format|3)"; std::string buffer(ctx); ctx.close(); char msgBuf[1024]; memset(msgBuf, 0, sizeof(msgBuf)); EXPECT_EQ(android_log_buffer_to_string(buffer.data(), buffer.length(), msgBuf, sizeof(msgBuf)), 0); EXPECT_STREQ(msgBuf, "[1005,tag_def,(tag|1),(name|3),(format|3)]"); } #endif // USING_LOGGER_DEFAULT #endif // USING_LOGGER_DEFAULT #ifdef USING_LOGGER_DEFAULT // Do not retest pmsg functionality #ifdef USING_LOGGER_DEFAULT // Do not retest pmsg functionality Loading liblog/tests/liblog_test_default.cpp +1 −0 Original line number Original line Diff line number Diff line Loading @@ -2,4 +2,5 @@ #include <log/log_transport.h> #include <log/log_transport.h> #define TEST_LOGGER LOGGER_DEFAULT #define TEST_LOGGER LOGGER_DEFAULT #endif #endif #define USING_LOGGER_DEFAULT #include "liblog_test.cpp" #include "liblog_test.cpp" Loading
liblog/tests/liblog_test.cpp +0 −15 Original line number Original line Diff line number Diff line Loading @@ -3004,21 +3004,6 @@ TEST(liblog, create_android_logger_overflow) { EXPECT_LE(0, android_log_destroy(&ctx)); EXPECT_LE(0, android_log_destroy(&ctx)); ASSERT_TRUE(NULL == ctx); ASSERT_TRUE(NULL == ctx); } } TEST(liblog, android_log_write_list_buffer) { __android_log_event_list ctx(1005); ctx << 1005 << "tag_def" << "(tag|1),(name|3),(format|3)"; std::string buffer(ctx); ctx.close(); char msgBuf[1024]; memset(msgBuf, 0, sizeof(msgBuf)); EXPECT_EQ(android_log_buffer_to_string(buffer.data(), buffer.length(), msgBuf, sizeof(msgBuf)), 0); EXPECT_STREQ(msgBuf, "[1005,tag_def,(tag|1),(name|3),(format|3)]"); } #endif // USING_LOGGER_DEFAULT #endif // USING_LOGGER_DEFAULT #ifdef USING_LOGGER_DEFAULT // Do not retest pmsg functionality #ifdef USING_LOGGER_DEFAULT // Do not retest pmsg functionality Loading
liblog/tests/liblog_test_default.cpp +1 −0 Original line number Original line Diff line number Diff line Loading @@ -2,4 +2,5 @@ #include <log/log_transport.h> #include <log/log_transport.h> #define TEST_LOGGER LOGGER_DEFAULT #define TEST_LOGGER LOGGER_DEFAULT #endif #endif #define USING_LOGGER_DEFAULT #include "liblog_test.cpp" #include "liblog_test.cpp"