From 275e260a6cd4a8e506ba974feb85ebcd926c1739 Mon Sep 17 00:00:00 2001 From: Ryan Harrison Date: Mon, 18 Sep 2017 14:23:18 -0400 Subject: Convert string class names Automated using git grep & sed. Replace StringC classes with StringView classes. Remove the CFX_ prefix and put string classes in fxcrt namespace. Change AsStringC() to AsStringView(). Rename tests from TEST(fxcrt, *String*Foo) to TEST(*String*, Foo). Couple of tests needed to have their names regularlized. BUG=pdfium:894 Change-Id: I7ca038685c8d803795f3ed02545124f7a224c83d Reviewed-on: https://pdfium-review.googlesource.com/14151 Reviewed-by: Tom Sepez Commit-Queue: Ryan Harrison --- .../page/cpdf_streamcontentparser_unittest.cpp | 40 +++++++++++----------- 1 file changed, 20 insertions(+), 20 deletions(-) (limited to 'core/fpdfapi/page/cpdf_streamcontentparser_unittest.cpp') diff --git a/core/fpdfapi/page/cpdf_streamcontentparser_unittest.cpp b/core/fpdfapi/page/cpdf_streamcontentparser_unittest.cpp index 6b43935a1d..0f4fc1e87a 100644 --- a/core/fpdfapi/page/cpdf_streamcontentparser_unittest.cpp +++ b/core/fpdfapi/page/cpdf_streamcontentparser_unittest.cpp @@ -6,39 +6,39 @@ #include "testing/gtest/include/gtest/gtest.h" TEST(cpdf_streamcontentparser, PDF_FindKeyAbbreviation) { - EXPECT_EQ(CFX_ByteStringC("BitsPerComponent"), + EXPECT_EQ(ByteStringView("BitsPerComponent"), CPDF_StreamContentParser::FindKeyAbbreviationForTesting( - CFX_ByteStringC("BPC"))); - EXPECT_EQ(CFX_ByteStringC("Width"), + ByteStringView("BPC"))); + EXPECT_EQ(ByteStringView("Width"), CPDF_StreamContentParser::FindKeyAbbreviationForTesting( - CFX_ByteStringC("W"))); - EXPECT_EQ(CFX_ByteStringC(""), + ByteStringView("W"))); + EXPECT_EQ(ByteStringView(""), CPDF_StreamContentParser::FindKeyAbbreviationForTesting( - CFX_ByteStringC(""))); - EXPECT_EQ(CFX_ByteStringC(""), + ByteStringView(""))); + EXPECT_EQ(ByteStringView(""), CPDF_StreamContentParser::FindKeyAbbreviationForTesting( - CFX_ByteStringC("NoInList"))); + ByteStringView("NoInList"))); // Prefix should not match. - EXPECT_EQ(CFX_ByteStringC(""), + EXPECT_EQ(ByteStringView(""), CPDF_StreamContentParser::FindKeyAbbreviationForTesting( - CFX_ByteStringC("WW"))); + ByteStringView("WW"))); } TEST(cpdf_streamcontentparser, PDF_FindValueAbbreviation) { - EXPECT_EQ(CFX_ByteStringC("DeviceGray"), + EXPECT_EQ(ByteStringView("DeviceGray"), CPDF_StreamContentParser::FindValueAbbreviationForTesting( - CFX_ByteStringC("G"))); - EXPECT_EQ(CFX_ByteStringC("DCTDecode"), + ByteStringView("G"))); + EXPECT_EQ(ByteStringView("DCTDecode"), CPDF_StreamContentParser::FindValueAbbreviationForTesting( - CFX_ByteStringC("DCT"))); - EXPECT_EQ(CFX_ByteStringC(""), + ByteStringView("DCT"))); + EXPECT_EQ(ByteStringView(""), CPDF_StreamContentParser::FindValueAbbreviationForTesting( - CFX_ByteStringC(""))); - EXPECT_EQ(CFX_ByteStringC(""), + ByteStringView(""))); + EXPECT_EQ(ByteStringView(""), CPDF_StreamContentParser::FindValueAbbreviationForTesting( - CFX_ByteStringC("NoInList"))); + ByteStringView("NoInList"))); // Prefix should not match. - EXPECT_EQ(CFX_ByteStringC(""), + EXPECT_EQ(ByteStringView(""), CPDF_StreamContentParser::FindValueAbbreviationForTesting( - CFX_ByteStringC("II"))); + ByteStringView("II"))); } -- cgit v1.2.3