diff --git a/util/misc/uuid_test.cc b/util/misc/uuid_test.cc index 39ccf6b..01f3b6a 100644 --- a/util/misc/uuid_test.cc +++ b/util/misc/uuid_test.cc @@ -19,6 +19,7 @@ #include #include "base/basictypes.h" +#include "base/format_macros.h" #include "base/strings/stringprintf.h" #include "gtest/gtest.h" @@ -180,8 +181,8 @@ TEST(UUID, FromString) { for (size_t index = 0; index < arraysize(kCases); ++index) { const TestCase& test_case = kCases[index]; - SCOPED_TRACE( - base::StringPrintf("index %zu: %s", index, test_case.uuid_string)); + SCOPED_TRACE(base::StringPrintf( + "index %" PRIuS ": %s", index, test_case.uuid_string)); UUID uuid; EXPECT_EQ(test_case.success, diff --git a/util/numeric/checked_range_test.cc b/util/numeric/checked_range_test.cc index 37d482c..9c72526 100644 --- a/util/numeric/checked_range_test.cc +++ b/util/numeric/checked_range_test.cc @@ -19,6 +19,7 @@ #include #include "base/basictypes.h" +#include "base/format_macros.h" #include "base/strings/stringprintf.h" #include "gtest/gtest.h" @@ -78,7 +79,8 @@ TEST(CheckedRange, IsValid) { for (size_t index = 0; index < arraysize(kUnsignedTestData); ++index) { const UnsignedTestData& testcase = kUnsignedTestData[index]; - SCOPED_TRACE(base::StringPrintf("unsigned index %zu, base 0x%x, size 0x%x", + SCOPED_TRACE(base::StringPrintf("unsigned index %" PRIuS + ", base 0x%x, size 0x%x", index, testcase.base, testcase.size)); @@ -139,7 +141,8 @@ TEST(CheckedRange, IsValid) { for (size_t index = 0; index < arraysize(kSignedTestData); ++index) { const SignedTestData& testcase = kSignedTestData[index]; - SCOPED_TRACE(base::StringPrintf("signed index %zu, base 0x%x, size 0x%x", + SCOPED_TRACE(base::StringPrintf("signed index %" PRIuS + ", base 0x%x, size 0x%x", index, testcase.base, testcase.size)); @@ -184,8 +187,8 @@ TEST(CheckedRange, ContainsValue) { for (size_t index = 0; index < arraysize(kTestData); ++index) { const TestData& testcase = kTestData[index]; - SCOPED_TRACE( - base::StringPrintf("index %zu, value 0x%x", index, testcase.value)); + SCOPED_TRACE(base::StringPrintf( + "index %" PRIuS ", value 0x%x", index, testcase.value)); EXPECT_EQ(testcase.valid, parent_range.ContainsValue(testcase.value)); } @@ -232,7 +235,7 @@ TEST(CheckedRange, ContainsRange) { for (size_t index = 0; index < arraysize(kTestData); ++index) { const TestData& testcase = kTestData[index]; - SCOPED_TRACE(base::StringPrintf("index %zu, base 0x%x, size 0x%x", + SCOPED_TRACE(base::StringPrintf("index %" PRIuS ", base 0x%x, size 0x%x", index, testcase.base, testcase.size)); diff --git a/util/stdlib/strlcpy_test.cc b/util/stdlib/strlcpy_test.cc index 0fac9e0..b9af201 100644 --- a/util/stdlib/strlcpy_test.cc +++ b/util/stdlib/strlcpy_test.cc @@ -19,6 +19,7 @@ #include #include "base/basictypes.h" +#include "base/format_macros.h" #include "base/strings/string16.h" #include "base/strings/stringprintf.h" #include "gtest/gtest.h" @@ -45,9 +46,10 @@ TEST(strlcpy, c16lcpy) { for (size_t index = 0; index < arraysize(test_characters); ++index) { base::char16 test_character = test_characters[index]; SCOPED_TRACE(base::StringPrintf( - "character index %zu, character 0x%x", index, test_character)); + "character index %" PRIuS ", character 0x%x", index, test_character)); for (size_t length = 0; length < 256; ++length) { - SCOPED_TRACE(base::StringPrintf("index %zu", length)); + SCOPED_TRACE( + base::StringPrintf("index %" PRIuS, length)); base::string16 test_string(length, test_character); TestBuffer destination;