diff options
Diffstat (limited to 'fpdfsdk/fpdf_formfill_embeddertest.cpp')
-rw-r--r-- | fpdfsdk/fpdf_formfill_embeddertest.cpp | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/fpdfsdk/fpdf_formfill_embeddertest.cpp b/fpdfsdk/fpdf_formfill_embeddertest.cpp index 8ff3a84291..3e53753b48 100644 --- a/fpdfsdk/fpdf_formfill_embeddertest.cpp +++ b/fpdfsdk/fpdf_formfill_embeddertest.cpp @@ -379,6 +379,25 @@ TEST_F(FPDFFormFillEmbeddertest, BUG_514690) { UnloadPage(page); } +class DoURIActionBlockedDelegate final : public EmbedderTest::Delegate { + public: + void DoURIAction(FPDF_BYTESTRING uri) override { + FAIL() << "Navigated to " << uri; + } +}; + +TEST_F(FPDFFormFillEmbeddertest, BUG_851821) { + DoURIActionBlockedDelegate delegate; + SetDelegate(&delegate); + + EXPECT_TRUE(OpenDocument("redirect.pdf")); + FPDF_PAGE page = LoadPage(0); + EXPECT_TRUE(page); + DoOpenActions(); + + UnloadPage(page); +} + #ifdef PDF_ENABLE_V8 TEST_F(FPDFFormFillEmbeddertest, DisableJavaScript) { // Test that timers and intervals can't fire without JS. |