diff --git a/paddle/fluid/string/string_helper_test.cc b/paddle/fluid/string/string_helper_test.cc index deeb4bdcc829179f10669d716d26284bac9f5e8f..4796bf7507aba7f8afac06dc33f08c7025b33d4b 100644 --- a/paddle/fluid/string/string_helper_test.cc +++ b/paddle/fluid/string/string_helper_test.cc @@ -33,10 +33,10 @@ TEST(StringHelper, EndsWith) { TEST(StringHelper, FormatStringAppend) { std::string str("hello"); - char fmt[] = "hhh"; + char fmt[] = "%d"; - paddle::string::format_string_append(str, fmt); - EXPECT_EQ(str, "hellohhh"); + paddle::string::format_string_append(str, fmt, 10); + EXPECT_EQ(str, "hello10"); } TEST(StringHelper, JoinStrings) {