summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTom Sepez <tsepez@chromium.org>2015-11-20 12:12:46 -0800
committerTom Sepez <tsepez@chromium.org>2015-11-20 12:12:46 -0800
commitf288bb1ca69c372e5c0037ce130667fc8462a7af (patch)
tree6426f47ac0f6cd7fe808f6609e685872d0ab1ce6
parent326a2a78aaf7e0146bfcd283da888c08e34143f8 (diff)
downloadpdfium-f288bb1ca69c372e5c0037ce130667fc8462a7af.tar.xz
Merge to XFA: Initialize V8 before starting embedder tests
Pull Jochen's fix before it is forgotten. Original Review URL: https://codereview.chromium.org/1462313002 . (cherry picked from commit 3ccd36892fe826e8f2ed8dde0819756ae3546733) TBR=jochen@chromium.org TBR=thestig@chromium.org Review URL: https://codereview.chromium.org/1470443002 .
-rw-r--r--testing/embedder_test.cpp9
1 files changed, 4 insertions, 5 deletions
diff --git a/testing/embedder_test.cpp b/testing/embedder_test.cpp
index c57126f320..39f3d50eb7 100644
--- a/testing/embedder_test.cpp
+++ b/testing/embedder_test.cpp
@@ -46,12 +46,7 @@ EmbedderTest::EmbedderTest()
memset(&file_access_, 0, sizeof(file_access_));
memset(&file_avail_, 0, sizeof(file_avail_));
delegate_ = default_delegate_.get();
-}
-
-EmbedderTest::~EmbedderTest() {
-}
-void EmbedderTest::SetUp() {
#ifdef PDF_ENABLE_V8
#ifdef V8_USE_EXTERNAL_STARTUP_DATA
InitializeV8ForPDFium(g_exe_path_, std::string(), &natives_, &snapshot_,
@@ -60,7 +55,11 @@ void EmbedderTest::SetUp() {
InitializeV8ForPDFium(&platform_);
#endif // V8_USE_EXTERNAL_STARTUP_DATA
#endif // FPDF_ENABLE_V8
+}
+
+EmbedderTest::~EmbedderTest() {}
+void EmbedderTest::SetUp() {
FPDF_LIBRARY_CONFIG config;
config.version = 2;
config.m_pUserFontPaths = nullptr;