Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2348)

Unified Diff: core/fxcrt/cfx_count_ref_unittest.cpp

Issue 2283113002: Add -> operators to CFX_CountRef. (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@privatize
Patch Set: Regenerate patch, rebase off of master. Created 4 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « core/fpdftext/cpdf_textpage.cpp ('k') | core/fxcrt/include/cfx_count_ref.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: core/fxcrt/cfx_count_ref_unittest.cpp
diff --git a/core/fxcrt/cfx_count_ref_unittest.cpp b/core/fxcrt/cfx_count_ref_unittest.cpp
index 7651c93f251ccf7c40a9449dcbc130e9f3c5cd9c..2a36292b541ec1f80613a1ba5b15910e53611d7c 100644
--- a/core/fxcrt/cfx_count_ref_unittest.cpp
+++ b/core/fxcrt/cfx_count_ref_unittest.cpp
@@ -109,16 +109,19 @@ TEST(fxcrt, CountRefGetModify) {
Observer observer;
{
CFX_CountRef<Object> ptr;
- EXPECT_NE(nullptr, ptr.GetPrivateCopy(&observer, std::string("one")));
+ ptr.MakePrivateCopy(&observer, std::string("one"));
+ EXPECT_NE(nullptr, ptr.GetObject());
EXPECT_EQ(1, observer.GetConstructionCount("one"));
EXPECT_EQ(0, observer.GetDestructionCount("one"));
- EXPECT_NE(nullptr, ptr.GetPrivateCopy(&observer, std::string("one")));
+ ptr.MakePrivateCopy(&observer, std::string("one"));
+ EXPECT_NE(nullptr, ptr.GetObject());
EXPECT_EQ(1, observer.GetConstructionCount("one"));
EXPECT_EQ(0, observer.GetDestructionCount("one"));
{
CFX_CountRef<Object> other(ptr);
- EXPECT_NE(nullptr, ptr.GetPrivateCopy(&observer, std::string("one")));
+ ptr.MakePrivateCopy(&observer, std::string("one"));
+ EXPECT_NE(nullptr, ptr.GetObject());
EXPECT_EQ(2, observer.GetConstructionCount("one"));
EXPECT_EQ(0, observer.GetDestructionCount("one"));
}
« no previous file with comments | « core/fpdftext/cpdf_textpage.cpp ('k') | core/fxcrt/include/cfx_count_ref.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698