| Index: testing/embedder_test.cpp
 | 
| diff --git a/testing/embedder_test.cpp b/testing/embedder_test.cpp
 | 
| index 33c72201a1fb70938c6669bf691d95782e00c4fb..e99c2e351abecd849532abe03f38bb5f235835ba 100644
 | 
| --- a/testing/embedder_test.cpp
 | 
| +++ b/testing/embedder_test.cpp
 | 
| @@ -93,6 +93,15 @@ void EmbedderTest::TearDown() {
 | 
|    free(file_contents_);
 | 
|  }
 | 
|  
 | 
| +bool EmbedderTest::CreateEmptyDocument() {
 | 
| +  document_ = FPDF_CreateNewDocument();
 | 
| +  if (!document_)
 | 
| +    return false;
 | 
| +
 | 
| +  SetupFormFillEnvironment();
 | 
| +  return true;
 | 
| +}
 | 
| +
 | 
|  bool EmbedderTest::OpenDocument(const std::string& filename,
 | 
|                                  bool must_linearize) {
 | 
|    std::string file_path;
 | 
| @@ -152,7 +161,11 @@ bool EmbedderTest::OpenDocument(const std::string& filename,
 | 
|    }
 | 
|  
 | 
|    (void)FPDF_GetDocPermissions(document_);
 | 
| +  SetupFormFillEnvironment();
 | 
| +  return true;
 | 
| +}
 | 
|  
 | 
| +void EmbedderTest::SetupFormFillEnvironment() {
 | 
|    IPDF_JSPLATFORM* platform = static_cast<IPDF_JSPLATFORM*>(this);
 | 
|    memset(platform, 0, sizeof(IPDF_JSPLATFORM));
 | 
|    platform->version = 2;
 | 
| @@ -169,8 +182,6 @@ bool EmbedderTest::OpenDocument(const std::string& filename,
 | 
|    form_handle_ = FPDFDOC_InitFormFillEnvironment(document_, formfillinfo);
 | 
|    FPDF_SetFormFieldHighlightColor(form_handle_, 0, 0xFFE4DD);
 | 
|    FPDF_SetFormFieldHighlightAlpha(form_handle_, 100);
 | 
| -
 | 
| -  return true;
 | 
|  }
 | 
|  
 | 
|  void EmbedderTest::DoOpenActions() {
 | 
| 
 |