OLD | NEW |
1 // Copyright 2015 PDFium Authors. All rights reserved. | 1 // Copyright 2015 PDFium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 | 5 |
6 #include "../../public/fpdf_formfill.h" | 6 #include "../../public/fpdf_formfill.h" |
7 #include "../../testing/embedder_test.h" | 7 #include "../../testing/embedder_test.h" |
8 #include "../../testing/embedder_test_mock_delegate.h" | 8 #include "../../testing/embedder_test_mock_delegate.h" |
9 #include "../../testing/embedder_test_timer_handling_delegate.h" | 9 #include "../../testing/embedder_test_timer_handling_delegate.h" |
10 #include "testing/gmock/include/gmock/gmock.h" | 10 #include "testing/gmock/include/gmock/gmock.h" |
(...skipping 23 matching lines...) Expand all Loading... |
34 EmbedderTestTimerHandlingDelegate delegate; | 34 EmbedderTestTimerHandlingDelegate delegate; |
35 SetDelegate(&delegate); | 35 SetDelegate(&delegate); |
36 | 36 |
37 EXPECT_TRUE(OpenDocument("testing/resources/bug_487928.pdf")); | 37 EXPECT_TRUE(OpenDocument("testing/resources/bug_487928.pdf")); |
38 FPDF_PAGE page = LoadPage(0); | 38 FPDF_PAGE page = LoadPage(0); |
39 EXPECT_NE(nullptr, page); | 39 EXPECT_NE(nullptr, page); |
40 DoOpenActions(); | 40 DoOpenActions(); |
41 delegate.AdvanceTime(5000); | 41 delegate.AdvanceTime(5000); |
42 UnloadPage(page); | 42 UnloadPage(page); |
43 } | 43 } |
| 44 |
| 45 TEST_F(FPDFFormFillEmbeddertest, BUG_514690) { |
| 46 EXPECT_TRUE(OpenDocument("testing/resources/hello_world.pdf")); |
| 47 FPDF_PAGE page = LoadPage(0); |
| 48 EXPECT_NE(nullptr, page); |
| 49 |
| 50 // Test that FORM_OnMouseMove() etc. permit null HANDLES and PAGES. |
| 51 FORM_OnMouseMove(nullptr, page, 0, 10.0, 10.0); |
| 52 FORM_OnMouseMove(form_handle(), nullptr, 0, 10.0, 10.0); |
| 53 |
| 54 UnloadPage(page); |
| 55 } |
OLD | NEW |