20 #include "gmock/gmock.h" 21 #include "gtest/gtest.h" 27 std::string str =
"ABC";
29 EXPECT_EQ(str,
"ABCDEF");
33 std::stringstream str;
36 EXPECT_EQ(str.str(),
"ABCDEF");
39 TEST(BufferRawSink, Limits) {
43 str_format_internal::BufferRawSink bufsink(buf,
sizeof(buf) - 1);
45 EXPECT_EQ(std::string(buf,
sizeof(buf)),
"Hello World237xx");
49 str_format_internal::BufferRawSink bufsink(buf,
sizeof(buf) - 1);
51 EXPECT_EQ(std::string(buf,
sizeof(buf)),
"Hello World2372x");
55 str_format_internal::BufferRawSink bufsink(buf,
sizeof(buf) - 1);
58 EXPECT_EQ(std::string(buf,
sizeof(buf)),
"Hello World237xx");
62 str_format_internal::BufferRawSink bufsink(buf,
sizeof(buf) - 1);
65 EXPECT_EQ(std::string(buf,
sizeof(buf)),
"Hello World2372x");
TEST(NotificationTest, SanityTest)