summaryrefslogtreecommitdiff
path: root/fpdfsdk/fpdfedit_embeddertest.cpp
diff options
context:
space:
mode:
authorLei Zhang <thestig@chromium.org>2018-02-12 14:58:44 +0000
committerChromium commit bot <commit-bot@chromium.org>2018-02-12 14:58:44 +0000
commitc113c7aa67aac8ce597a1c15da065389bba36b9b (patch)
treee0dc1e16034ab5d2d7a532b20721e3ad2d073ceb /fpdfsdk/fpdfedit_embeddertest.cpp
parent9e705dfe91b1cc36a3333c963500a656a0e635a8 (diff)
downloadpdfium-c113c7aa67aac8ce597a1c15da065389bba36b9b.tar.xz
Get rid of EmbedderTest::RenderPageWithFlagsDeprecated().
Change-Id: I653619faa61181137795bb3675418fd8d0945d25 Reviewed-on: https://pdfium-review.googlesource.com/25590 Commit-Queue: dsinclair <dsinclair@chromium.org> Reviewed-by: dsinclair <dsinclair@chromium.org>
Diffstat (limited to 'fpdfsdk/fpdfedit_embeddertest.cpp')
-rw-r--r--fpdfsdk/fpdfedit_embeddertest.cpp13
1 files changed, 7 insertions, 6 deletions
diff --git a/fpdfsdk/fpdfedit_embeddertest.cpp b/fpdfsdk/fpdfedit_embeddertest.cpp
index 3787318418..8c97d42365 100644
--- a/fpdfsdk/fpdfedit_embeddertest.cpp
+++ b/fpdfsdk/fpdfedit_embeddertest.cpp
@@ -483,11 +483,12 @@ TEST_F(FPDFEditEmbeddertest, EditOverExistingContent) {
EXPECT_TRUE(FPDFPath_SetFillColor(green_rect2, 0, 255, 0, 100));
EXPECT_TRUE(FPDFPath_SetDrawMode(green_rect2, FPDF_FILLMODE_ALTERNATE, 0));
FPDFPage_InsertObject(saved_page, green_rect2);
- FPDF_BITMAP new_bitmap =
- RenderPageWithFlagsDeprecated(saved_page, saved_form_handle_, 0);
- const char last_md5[] = "4b5b00f824620f8c9b8801ebb98e1cdd";
- CompareBitmap(new_bitmap, 612, 792, last_md5);
- FPDFBitmap_Destroy(new_bitmap);
+ const char kLastMD5[] = "4b5b00f824620f8c9b8801ebb98e1cdd";
+ {
+ std::unique_ptr<void, FPDFBitmapDeleter> new_bitmap =
+ RenderSavedPage(saved_page);
+ CompareBitmap(new_bitmap.get(), 612, 792, kLastMD5);
+ }
EXPECT_TRUE(FPDFPage_GenerateContent(saved_page));
// Now save the result, closing the page and document
@@ -497,7 +498,7 @@ TEST_F(FPDFEditEmbeddertest, EditOverExistingContent) {
CloseSavedDocument();
// Render the saved result
- VerifySavedDocument(612, 792, last_md5);
+ VerifySavedDocument(612, 792, kLastMD5);
}
TEST_F(FPDFEditEmbeddertest, AddStrokedPaths) {